i18n linters - ESLint Vue
Part of https://gitlab.com/gitlab-org/manage/issues/20
We can lint for unwrapped strings (in simple/common cases) in Vue files using ESLint and the eslint-plugin-vue package.
-
We should use dangerAdd ESLint rules to enforce externalization in the changes of a branch going forward.
After reading the issue tracker it seems other contributors to the plugin also want a no-bare-strings
rule.
Started in lbennett/eslint-plugin-vue!1 (closed). Still needs autofix functionality and needs to be verified against our codebase instead of just test cases.
Steps taken
-
Configure vue-i18n for gitlab -
Lint gitlab -
gitlab-ce#63457 Autofix gitlab repo -
gitlab-ce#63458 Log issues for non-autofixable lints (#29604)
-
-
gitlab-ce#63560 Integrate vue-i18n plugin into gitlab -
Publish eslint-plugin-vue-i18n -
https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/31124/diffs?commit_id=d46af03ef3eacbeb858e4fde67cb4e4bf8412811 Apply to master -
https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/14929 Apply to EE master -
https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/31124/diffs?commit_id=f418214deccbdd9178c5582156a378cde2a94def eslint-disable all the outstanding lint errors that were not autofixed
-