-
-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Stricter eslint checks and a ton of resultant updates
- Loading branch information
Showing
118 changed files
with
1,651 additions
and
1,227 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
/* eslint-env node */ | ||
|
||
module.exports = { | ||
env: { | ||
browser: true, | ||
node: true, | ||
}, | ||
extends: [ | ||
'eslint:recommended', | ||
'plugin:jsx-a11y/recommended', | ||
'plugin:@typescript-eslint/strict-type-checked', | ||
'plugin:@typescript-eslint/stylistic-type-checked', | ||
'next/core-web-vitals', | ||
'prettier', | ||
], | ||
overrides: [ | ||
{ | ||
extends: ['plugin:@typescript-eslint/disable-type-checked'], | ||
files: ['./**/*.{js,cjs}'], | ||
}, | ||
], | ||
ignorePatterns: ['next.config.mjs', 'jest.config.mjs'], | ||
parser: '@typescript-eslint/parser', | ||
parserOptions: { project: true, tsconfigRootDir: __dirname }, | ||
plugins: ['@emotion', 'lingui'], | ||
rules: { | ||
// someday?... "lingui/no-unlocalized-strings": 2, | ||
'lingui/t-call-in-function': 2, | ||
'lingui/no-single-variables-to-translate': 2, | ||
'lingui/no-expression-in-message': 2, | ||
'lingui/no-single-tag-to-translate': 2, | ||
'lingui/no-trans-inside-trans': 2, | ||
'@emotion/pkg-renaming': 'error', | ||
'jsx-a11y/anchor-is-valid': [ | ||
'error', | ||
{ | ||
components: ['Link'], | ||
}, | ||
], | ||
'jsx-a11y/anchor-has-content': [ | ||
'error', | ||
{ | ||
components: ['Link'], | ||
}, | ||
], | ||
'linebreak-style': ['error', 'unix'], | ||
semi: ['error', 'always'], | ||
'@typescript-eslint/strict-boolean-expressions': [ | ||
'error', | ||
{ | ||
allowNullableBoolean: true, | ||
allowNullableNumber: true, | ||
allowNullableString: true, | ||
}, | ||
], | ||
'@typescript-eslint/no-unused-vars': [ | ||
'error', | ||
{ | ||
argsIgnorePattern: '^_', | ||
}, | ||
], | ||
|
||
// TODO get this turned on, it's just a lot to update all at once. | ||
'@typescript-eslint/prefer-nullish-coalescing': 'off' | ||
}, | ||
}; |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.