Skip to content

Commit

Permalink
add comments
Browse files Browse the repository at this point in the history
  • Loading branch information
goosewobbler committed Jan 14, 2023
1 parent e14013c commit bf9d16c
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import globals from 'globals'

export default [
'eslint:recommended',
// All files
{
files: ['**/*.{js,mjs,ts,tsx}'],
languageOptions: {
Expand All @@ -22,6 +23,7 @@ export default [
'no-unused-vars': ['error', { ignoreRestSiblings: true, destructuredArrayIgnorePattern: '^_' }]
}
},
// Main process files and scripts
{
files: ['**/*.{js,mjs,ts}'],
ignores: ['app/**/*', 'resources/Components/**/*'],
Expand All @@ -31,6 +33,7 @@ export default [
}
}
},
// TS files
{
files: ['**/*.{ts,tsx}'],
languageOptions: {
Expand All @@ -46,10 +49,11 @@ export default [
},
rules: {
...ts.configs['eslint-recommended'].rules,
...ts.configs['recommended'].rules,
'no-undef': 'off' // redundant rule - TS will fail to compile with undefined vars
...ts.configs.recommended.rules,
'no-undef': 'off' // redundant - TS will fail to compile with undefined vars
}
},
// React / JSX files
{
files: [
'app/**/*.js',
Expand Down Expand Up @@ -82,6 +86,7 @@ export default [
'react/prop-types': 'off' // all type checking to be done in TS
}
},
// Renderer process files
{
files: [
'app/**/*.js',
Expand All @@ -95,6 +100,7 @@ export default [
}
}
},
// Test files
{
files: ['test/**/*', '**/__mocks__/**/*'],
plugins: {
Expand All @@ -110,6 +116,7 @@ export default [
// ...jest.configs.recommended.rules
// }
},
// Components test files
{
files: ['test/app/**/*.js', 'test/resources/Components/**/*.js', 'app/**/__mocks__/**'],
plugins: {
Expand Down

0 comments on commit bf9d16c

Please sign in to comment.