-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Upgrade node and pnpm for local dev * Upgrade devDependencies other than eslint and RTL * Upgrade Vitest and related libraries * Upgrade ESLint and migrate to flat config * Upgrade remaining dependencies and fix all scripts
- Loading branch information
Showing
9 changed files
with
6,973 additions
and
3,958 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
20.11.0 | ||
22.10.0 |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,9 @@ | ||
{ | ||
"extends": "../../tsconfig-base.typecheck.json", | ||
|
||
"compilerOptions": { | ||
"types": ["@testing-library/jest-dom"] | ||
}, | ||
|
||
"include": ["*.ts", "src"] | ||
} |
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,68 @@ | ||
import { fixupPluginRules } from '@eslint/compat'; | ||
import eslintJs from '@eslint/js'; | ||
import eslintConfigPrettier from 'eslint-config-prettier'; | ||
import eslintConfigReactApp from 'eslint-config-react-app'; | ||
import eslintPluginFlowtype from 'eslint-plugin-flowtype'; | ||
import eslintPluginImport from 'eslint-plugin-import'; | ||
import eslintPluginJsxA11y from 'eslint-plugin-jsx-a11y'; | ||
import reactRecommended from 'eslint-plugin-react/configs/recommended.js'; | ||
import eslintPluginReactHooks from 'eslint-plugin-react-hooks'; | ||
import typescriptEslint from 'typescript-eslint'; | ||
|
||
const buildOutputs = [ | ||
'.docusaurus', | ||
'build', | ||
'coverage', | ||
'dist', | ||
'legacy-types', | ||
'node_modules', | ||
'storybook-static', | ||
]; | ||
const projectDirectoriesToIgnore = `{${buildOutputs.join(',')}}/**`; | ||
|
||
const eslintConfig = [ | ||
{ | ||
ignores: [ | ||
projectDirectoriesToIgnore, | ||
`demos/*/${projectDirectoriesToIgnore}`, | ||
`docs-website/${projectDirectoriesToIgnore}`, | ||
`packages/*/${projectDirectoriesToIgnore}`, | ||
// Each external-test has its own eslint config, following the conventions of its framework, so they're not included | ||
'external-tests/*/**', | ||
], | ||
}, | ||
{ | ||
plugins: { | ||
// These plugins are all needed for eslint-config-react-app | ||
flowtype: fixupPluginRules(eslintPluginFlowtype), | ||
'jsx-a11y': eslintPluginJsxA11y, | ||
import: fixupPluginRules(eslintPluginImport), | ||
'react-hooks': eslintPluginReactHooks, | ||
}, | ||
linterOptions: { | ||
reportUnusedDisableDirectives: true, | ||
}, | ||
settings: { | ||
react: { | ||
version: 'detect', | ||
}, | ||
}, | ||
}, | ||
|
||
eslintJs.configs.recommended, | ||
eslintConfigPrettier, | ||
reactRecommended, | ||
...typescriptEslint.configs.recommended, | ||
|
||
// Overrides: | ||
{ | ||
files: ['**/*.{js,ts,jsx,tsx,cjs,mjs}'], | ||
rules: { | ||
...eslintConfigReactApp.rules, | ||
...eslintConfigReactApp.overrides[0].rules, | ||
'react/react-in-jsx-scope': 'off', | ||
}, | ||
}, | ||
]; | ||
|
||
export default eslintConfig; |
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.