Skip to content

Commit

Permalink
feat: add eslint role for no message description
Browse files Browse the repository at this point in the history
  This uses an eslint role for getting strings with no
  descriptions, this for demonstration purpose and can be used
  for checking other MFEs or JS/React base repos

  Ref: openedx/wg-translations/issues/5
  • Loading branch information
ghassanmas committed Jul 19, 2023
1 parent 8ac9745 commit cd4024f
Show file tree
Hide file tree
Showing 3 changed files with 394 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
const { createConfig } = require('@edx/frontend-build');

const config = createConfig('eslint', {
// Docs for formatjs plugin:
// https://formatjs.io/docs/tooling/linter/#react
plugins: ['formatjs'],
rules: {
// TODO: all these rules should be renabled/addressed. temporarily turned off to unblock a release.
'react-hooks/rules-of-hooks': 'off',
Expand All @@ -11,6 +14,7 @@ const config = createConfig('eslint', {
'react/jsx-no-useless-fragment': 'off',
'react/no-unknown-property': 'off',
'func-names': 'off',
'formatjs/enforce-description': ['error', 'literal'],
},
});

Expand Down
Loading

0 comments on commit cd4024f

Please sign in to comment.