-
-
Notifications
You must be signed in to change notification settings - Fork 61
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
8287c33
commit 0c22d9a
Showing
5 changed files
with
181 additions
and
145 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
import simpleImportSort from 'eslint-plugin-simple-import-sort'; | ||
import tsParser from '@typescript-eslint/parser'; | ||
import path from 'node:path'; | ||
import { fileURLToPath } from 'node:url'; | ||
import js from '@eslint/js'; | ||
import { FlatCompat } from '@eslint/eslintrc'; | ||
|
||
const __filename = fileURLToPath(import.meta.url); | ||
const __dirname = path.dirname(__filename); | ||
const compat = new FlatCompat({ | ||
baseDirectory: __dirname, | ||
recommendedConfig: js.configs.recommended, | ||
allConfig: js.configs.all, | ||
}); | ||
|
||
export default [ | ||
{ | ||
ignores: [ | ||
'**/node_modules/', | ||
'**/lib/', | ||
'**/tmp/', | ||
'test/*.js', | ||
'**/templates/', | ||
'**/@types/', | ||
'**/*.js', | ||
'*/*.js', | ||
], | ||
}, | ||
...compat.extends('plugin:@typescript-eslint/recommended', 'plugin:prettier/recommended'), | ||
{ | ||
plugins: { | ||
'simple-import-sort': simpleImportSort, | ||
}, | ||
|
||
languageOptions: { | ||
parser: tsParser, | ||
}, | ||
|
||
rules: { | ||
'simple-import-sort/imports': 'error', | ||
'simple-import-sort/exports': 'error', | ||
|
||
quotes: [ | ||
2, | ||
'single', | ||
{ | ||
avoidEscape: true, | ||
}, | ||
], | ||
|
||
'no-debugger': 'off', | ||
'@typescript-eslint/no-explicit-any': 'off', | ||
'@typescript-eslint/no-misused-new': 'off', | ||
'@typescript-eslint/no-unused-expressions': 'off', | ||
'@typescript-eslint/triple-slash-reference': 'off', | ||
|
||
'@typescript-eslint/no-unused-vars': [ | ||
'error', | ||
{ | ||
argsIgnorePattern: '^_', | ||
varsIgnorePattern: '^_', | ||
caughtErrorsIgnorePattern: '^_', | ||
}, | ||
], | ||
|
||
camelcase: 'off', | ||
'@typescript-eslint/camelcase': 'off', | ||
}, | ||
}, | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,7 +16,7 @@ | |
"build:package": "yarn run build && rm -rf './dist/[email protected]' && cd ./dist && zip -qr '[email protected]' .", | ||
"watch": "yarn run build && yarn run rollup -c --watch", | ||
"test": "jasmine --module --no-config build/tests/", | ||
"lint": "eslint --ext .ts src/", | ||
"lint": "eslint src/", | ||
"shell:restart": "busctl --user call org.gnome.Shell /io/elhan/Pano io.elhan.Pano restart", | ||
"build-and-restart": "yarn run build && yarn run shell:restart", | ||
"prettier:check": "prettier --check .", | ||
|
@@ -36,6 +36,8 @@ | |
"devDependencies": { | ||
"@commitlint/cli": "^19.4.1", | ||
"@commitlint/config-conventional": "^19.4.1", | ||
"@eslint/eslintrc": "^3.1.0", | ||
"@eslint/js": "^9.9.1", | ||
"@girs/adw-1": "1.6.0-4.0.0-beta.15", | ||
"@girs/clutter-14": "14.0.0-4.0.0-beta.15", | ||
"@girs/gda-5.0": "5.0.0-4.0.0-beta.15", | ||
|
@@ -58,6 +60,9 @@ | |
"@rollup/plugin-node-resolve": "^15.2.3", | ||
"@rollup/plugin-typescript": "^11.1.6", | ||
"@tsconfig/strictest": "^2.0.5", | ||
"@types/eslint": "^9.6.1", | ||
"@types/eslint__js": "^8.42.3", | ||
"@types/eslint__eslintrc": "^2.1.2", | ||
"@types/events": "^3.0.3", | ||
"@types/gettext-parser": "^4.0.4", | ||
"@types/highlight.js": "^10.1.0", | ||
|
@@ -68,7 +73,7 @@ | |
"@typescript-eslint/parser": "^8.4.0", | ||
"chalk": "^4.1.2", | ||
"cross-env": "^7.0.3", | ||
"eslint": "^8.57.0", | ||
"eslint": "^9.9.1", | ||
"eslint-config-prettier": "^9.1.0", | ||
"eslint-plugin-prettier": "^5.2.1", | ||
"eslint-plugin-simple-import-sort": "^12.1.1", | ||
|
Oops, something went wrong.