mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-08 19:06:15 -08:00
refactor: Update ESLint configuration to use latest ECMAScript version and warn about indentation
This commit is contained in:
1 parent
2b8c1e2d32
commit
c08798fb05
2 files changed
+18
-16
No files matched your search
+2
-2
@@ -5,7 +5,7 @@ export default [
|
||||
js.configs.recommended,
|
||||
{
|
||||
languageOptions: {
|
||||
ecmaVersion: 2021,
|
||||
ecmaVersion: 'latest',
|
||||
sourceType: 'module',
|
||||
globals: {
|
||||
...globals.browser,
|
||||
@@ -14,7 +14,7 @@ export default [
|
||||
},
|
||||
rules: {
|
||||
'no-console': 'off',
|
||||
indent: ['error', 4],
|
||||
indent: ['warn', 4],
|
||||
'linebreak-style': ['error', 'unix'],
|
||||
quotes: ['error', 'single', { avoidEscape: true, allowTemplateLiterals: true }],
|
||||
semi: ['error', 'always'],
|
||||
|
||||
@@ -63,20 +63,22 @@ export default class Setting {
|
||||
art.on('fullscreenWeb', (state) => this.onFullscreen(state));
|
||||
}
|
||||
|
||||
static icons = {
|
||||
$on,
|
||||
$off,
|
||||
$config,
|
||||
$style,
|
||||
$mode_0_off,
|
||||
$mode_0_on,
|
||||
$mode_1_off,
|
||||
$mode_1_on,
|
||||
$mode_2_off,
|
||||
$mode_2_on,
|
||||
$check_on,
|
||||
$check_off,
|
||||
};
|
||||
static get icons() {
|
||||
return {
|
||||
$on,
|
||||
$off,
|
||||
$config,
|
||||
$style,
|
||||
$mode_0_off,
|
||||
$mode_0_on,
|
||||
$mode_1_off,
|
||||
$mode_1_on,
|
||||
$mode_2_off,
|
||||
$mode_2_on,
|
||||
$check_on,
|
||||
$check_off,
|
||||
};
|
||||
}
|
||||
|
||||
get option() {
|
||||
return this.danmuku.option;
|
||||
|
||||
Reference in new issue
Block a user