Skip to content

Commit

Permalink
fix eslint config
Browse files Browse the repository at this point in the history
  • Loading branch information
kcinay055679 committed Dec 20, 2024
1 parent 2fdc5c6 commit 262b149
Show file tree
Hide file tree
Showing 2 changed files with 5,841 additions and 26,405 deletions.
59 changes: 26 additions & 33 deletions frontend/eslint.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ export default tsEslint.config(
'@stylistic/object-property-newline': ['error'],
'@stylistic/multiline-ternary': ['off'],
'@stylistic/object-curly-spacing': ['error', 'always'],
'@stylistic/array-bracket-newline': ['error', { minItems: 4 }],
// '@stylistic/array-bracket-newline': ['error', { minItems: 4 }],
'@stylistic/semi-style': ['error'],
'space-before-function-paren': ['error', 'never'],
'@stylistic/function-paren-newline': ['error', { minItems: 4 }],
Expand All @@ -106,17 +106,8 @@ export default tsEslint.config(
'error',
{
type: 'attribute',
// reenable this after fixing all the directives
// prefix: 'app',
style: 'camelCase',
},
],
'@angular-eslint/component-selector': [
'error',
{
type: 'element',
prefix: 'app',
style: 'kebab-case',
style: 'camelCase',
},
],
'@angular-eslint/component-selector': [
Expand All @@ -142,27 +133,29 @@ export default tsEslint.config(
},
},

{
files: ['**/*.html'],
// recommended configuration included in the plugin
...html.configs['flat/recommended'],
languageOptions: {
parser: htmlParser,
},
rules: {
...html.configs['flat/recommended'].rules,
//Html eslint rules
'@html-eslint/require-img-alt': 'off',
'@html-eslint/indent': ['error', 2],
'@html-eslint/require-closing-tags': ['error', { selfClosing: 'always' }],
//Doesn't work with Angular 17+
'@html-eslint/element-newline': 'off',
},
{
plugins: {
'unused-imports': unusedImports,
'@stylistic': stylistic,
'@html-eslint': html,
{
files: ['**/*.html'],
// recommended configuration included in the plugin
...html.configs['flat/recommended'],
languageOptions: {
parser: htmlParser,
},
rules: {
...html.configs['flat/recommended'].rules,
//Html eslint rules
'@html-eslint/require-img-alt': 'off',
'@html-eslint/indent': ['error', 2],
'@html-eslint/require-closing-tags': ['error', {selfClosing: 'always'}],
//Doesn't work with Angular 17+
'@html-eslint/element-newline': 'off',
},
},
}
{
plugins: {
'unused-imports': unusedImports,
'@stylistic': stylistic,
'@html-eslint': html,
}
}

)
Loading

0 comments on commit 262b149

Please sign in to comment.