Skip to content

Commit 3517063

Browse files
committed
more linting
1 parent 164271c commit 3517063

File tree

7 files changed

+3763
-178
lines changed

7 files changed

+3763
-178
lines changed

.github/workflows/3d-visualiser.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,11 @@ jobs:
3333

3434
- name: Type check
3535
working-directory: ./3d-visualiser
36-
run: npx tsc --noEmit
36+
run: npm run typecheck
37+
38+
- name: Lint code
39+
working-directory: ./3d-visualiser
40+
run: npm run lint -- --format=compact
3741

3842
- name: Build project
3943
working-directory: ./3d-visualiser

3d-visualiser/eslint.config.js

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
import js from '@eslint/js';
2+
import tseslint from 'typescript-eslint';
3+
import pluginImport from 'eslint-plugin-import';
4+
5+
export default [
6+
{
7+
ignores: ['dist/**', 'node_modules/**']
8+
},
9+
js.configs.recommended,
10+
...tseslint.configs.recommended,
11+
{
12+
files: ['**/*.ts', '**/*.js'],
13+
plugins: { import: pluginImport },
14+
rules: {
15+
'@typescript-eslint/no-unused-vars': ['error', { argsIgnorePattern: '^_', varsIgnorePattern: '^_' }],
16+
'@typescript-eslint/no-explicit-any': 'warn',
17+
'no-console': 'warn',
18+
'no-debugger': 'error',
19+
'prefer-const': 'error',
20+
'no-var': 'error',
21+
'no-empty': ['warn', { allowEmptyCatch: true }],
22+
'import/order': [
23+
'error',
24+
{ groups: ['builtin', 'external', 'internal', 'parent', 'sibling', 'index'], 'newlines-between': 'always' }
25+
]
26+
}
27+
}
28+
];

0 commit comments

Comments
 (0)