Skip to content

Commit d8dbb16

Browse files
committed
chore(eslint): update eslint
1 parent af995e4 commit d8dbb16

File tree

25 files changed

+10516
-11387
lines changed

25 files changed

+10516
-11387
lines changed

.eslintignore

-12
This file was deleted.

.eslintrc.json

-60
This file was deleted.

.prettierrc.js

+6-9
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,8 @@
11
export default {
2-
"arrowParens": "avoid",
3-
"bracketSameLine": true,
4-
"trailingComma": "none",
5-
"singleQuote": true,
6-
"semi": true,
7-
"printWidth": 80,
8-
"bracketSameLine": false
2+
arrowParens: 'avoid',
3+
bracketSameLine: false,
4+
trailingComma: 'none',
5+
singleQuote: true,
6+
semi: true,
7+
printWidth: 80
98
};
10-
11-

docs/.vitepress/navigation.js

+4-1
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,10 @@ export default {
7373
collapsed: true,
7474
items: [
7575
{ text: 'useBoosterFont', link: '/composables/useBoosterFont' },
76-
{ text: 'useBoosterCritical', link: '/composables/useBoosterCritical' },
76+
{
77+
text: 'useBoosterCritical',
78+
link: '/composables/useBoosterCritical'
79+
},
7780
{ text: 'useBoosterConfig', link: '/composables/useBoosterConfig' },
7881
{
7982
text: 'useBoosterComponentObserver',

docs/.vitepress/theme/index.js

+1
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ export default {
1212
// https://vitepress.dev/guide/extending-default-theme#layout-slots
1313
});
1414
},
15+
// eslint-disable-next-line no-unused-vars
1516
enhanceApp({ app, router, siteData }) {
1617
// ...
1718
}

eslint.config.js

+55
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
import { createConfigForNuxt } from '@nuxt/eslint-config/flat';
2+
import eslintConfigPrettier from 'eslint-config-prettier';
3+
import eslintPluginPrettierRecommended from 'eslint-plugin-prettier/recommended';
4+
import eslintIgnores from './eslint.ignores.js';
5+
import eslintGlobals from './playground/.nuxt/.eslint.globals.mjs';
6+
import pluginSecurity from 'eslint-plugin-security';
7+
8+
export default createConfigForNuxt(
9+
{
10+
features: {
11+
typescript: false
12+
}
13+
},
14+
pluginSecurity.configs.recommended,
15+
eslintConfigPrettier,
16+
eslintPluginPrettierRecommended,
17+
eslintGlobals,
18+
19+
{
20+
files: ['**/*.js', '**/*.vue'],
21+
ignores: eslintIgnores,
22+
rules: {
23+
'prettier/prettier': 'error',
24+
classPrivateMethods: 'off',
25+
'block-spacing': 'error',
26+
'no-debugger': 'off',
27+
'no-console': 'off',
28+
'vue/no-v-html': 'off',
29+
'vue/no-mutating-props': 'off',
30+
'security/detect-non-literal-fs-filename': 'off',
31+
complexity: [
32+
'error',
33+
{
34+
max: 10
35+
}
36+
],
37+
'no-multiple-empty-lines': [
38+
'error',
39+
{
40+
max: 1,
41+
maxEOF: 1
42+
}
43+
],
44+
'vue/component-name-in-template-casing': [
45+
'error',
46+
'kebab-case',
47+
{
48+
registeredComponentsOnly: true,
49+
ignores: []
50+
}
51+
],
52+
'vue/multi-word-component-names': 'off'
53+
}
54+
}
55+
);

eslint.ignores.js

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
export default [
2+
// Common
3+
'node_modules',
4+
'dist',
5+
'.nuxt',
6+
'coverage',
7+
'.reports',
8+
'publish',
9+
'sw.js',
10+
'.output',
11+
12+
// Docs
13+
'docs/.vitepress/dist',
14+
'docs/.vitepress/cache'
15+
];

0 commit comments

Comments
 (0)