Skip to content

Commit 5708c40

Browse files
committed
Fix linting on samples app
1 parent 965cd15 commit 5708c40

3 files changed

Lines changed: 23 additions & 3 deletions

File tree

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
module.exports = {
2+
root: true,
3+
env: { browser: true, es2020: true },
4+
extends: [
5+
'eslint:recommended',
6+
'plugin:@typescript-eslint/recommended',
7+
'plugin:react-hooks/recommended',
8+
],
9+
ignorePatterns: ['dist', '.eslintrc.cjs', 'src/rest/*'],
10+
parser: '@typescript-eslint/parser',
11+
plugins: ['react-refresh'],
12+
rules: {
13+
'react-refresh/only-export-components': [
14+
'warn',
15+
{ allowConstantExport: true },
16+
],
17+
'@typescript-eslint/no-explicit-any': 'off',
18+
}
19+
}

applications/samples/frontend/.eslintrc.cjs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,14 @@ module.exports = {
66
'plugin:@typescript-eslint/recommended',
77
'plugin:react-hooks/recommended',
88
],
9-
ignorePatterns: ['dist', '.eslintrc.cjs', 'rest'],
9+
ignorePatterns: ['dist', '.eslintrc.cjs', 'src/rest/*'],
1010
parser: '@typescript-eslint/parser',
1111
plugins: ['react-refresh'],
1212
rules: {
1313
'react-refresh/only-export-components': [
1414
'warn',
1515
{ allowConstantExport: true },
1616
],
17-
''
17+
'@typescript-eslint/no-explicit-any': 'off',
1818
}
1919
}

applications/samples/frontend/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@
88
"start": "DOMAIN=http://localhost:5000 vite",
99
"start:dev": "DOMAIN=https://test.ch.metacell.us vite",
1010
"start:local": "DOMAIN=http://samples.ch vite",
11-
"build": "tsc -b && vite build",
11+
"prebuild": "eslint .",
12+
"build": "vite build",
1213
"lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
1314
"preview": "vite preview"
1415
},

0 commit comments

Comments
 (0)