Skip to content

Commit

Permalink
adopt eslint
Browse files Browse the repository at this point in the history
  • Loading branch information
samuelcolvin committed Nov 12, 2023
1 parent b3d6e95 commit 442327f
Show file tree
Hide file tree
Showing 24 changed files with 1,966 additions and 202 deletions.
28 changes: 25 additions & 3 deletions demo/.eslintrc.cjs
Original file line number Diff line number Diff line change
@@ -1,12 +1,34 @@
module.exports = {
root: true,
env: { browser: true, es2020: true },
extends: ['eslint:recommended', 'plugin:@typescript-eslint/recommended', 'plugin:react-hooks/recommended'],
ignorePatterns: ['dist', '.eslintrc.cjs'],
extends: [
'standard',
'eslint:recommended',
'plugin:@typescript-eslint/recommended',
'plugin:react-hooks/recommended',
],
ignorePatterns: ['dist', '.eslintrc.cjs', 'vite.config.ts'],
parser: '@typescript-eslint/parser',
plugins: ['react-refresh'],
plugins: ['react', '@typescript-eslint', 'react-refresh', 'simple-import-sort'],
rules: {
'react-refresh/only-export-components': ['warn', { allowConstantExport: true }],
'@typescript-eslint/no-explicit-any': 'off',
'import/order': [
'error',
{
'newlines-between': 'always',
groups: ['builtin', 'external', 'internal', 'object', 'type', 'parent', 'index', 'sibling'],
pathGroups: [
{
pattern: '@/**',
group: 'internal',
},
{
pattern: './../**',
group: 'parent',
},
],
},
],
},
}
Loading

0 comments on commit 442327f

Please sign in to comment.