-
-
Notifications
You must be signed in to change notification settings - Fork 46
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
e051967
commit eab4bcc
Showing
11 changed files
with
480 additions
and
428 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
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,102 @@ | ||
/* eslint-disable @typescript-eslint/no-require-imports */ | ||
|
||
const babelParser = require('@babel/eslint-parser'); | ||
const js = require('@eslint/js'); | ||
const prettier = require('eslint-config-prettier'); | ||
const importPlugin = require('eslint-plugin-import'); | ||
const jest = require('eslint-plugin-jest'); | ||
const jestDOM = require('eslint-plugin-jest-dom'); | ||
const simpleImportSort = require('eslint-plugin-simple-import-sort'); | ||
const globals = require('globals'); | ||
const tseslint = require('typescript-eslint'); | ||
|
||
module.exports = tseslint.config( | ||
{ | ||
ignores: [ | ||
'.git/*', | ||
'.nyc_output/*', | ||
'.vscode/*', | ||
'.yarn/*', | ||
'.yarnrc.yml', | ||
'coverage/*', | ||
'dist/*', | ||
'docs/*', | ||
'node_modules/*', | ||
], | ||
}, | ||
js.configs.recommended, | ||
...tseslint.configs.recommended, | ||
importPlugin.flatConfigs.recommended, | ||
prettier, | ||
{ | ||
files: ['**/*.{js,mjs,cjs,ts,cts,mts}'], | ||
languageOptions: { | ||
parser: babelParser, | ||
globals: { | ||
...globals.node, | ||
...globals.es2022, | ||
}, | ||
parserOptions: { | ||
sourceType: 'script', | ||
}, | ||
}, | ||
settings: { | ||
'import/resolver': { | ||
typescript: {}, | ||
}, | ||
'import/external-module-folders': ['node_modules'], | ||
}, | ||
rules: { | ||
'no-console': 1, | ||
'no-warning-comments': ['warn', { terms: ['todo', 'fixme', '@@@'] }], | ||
'import/first': 'warn', | ||
'import/newline-after-import': 'warn', | ||
'import/no-duplicates': ['error', { 'prefer-inline': true }], | ||
'import/order': [ | ||
'warn', | ||
{ 'newlines-between': 'always', alphabetize: { order: 'asc' } }, | ||
], | ||
'import/named': 'warn', | ||
}, | ||
}, | ||
{ | ||
files: ['src/**/*.{js,mjs,cjs,ts,cts,mts}'], | ||
languageOptions: { | ||
parser: tseslint.parser, | ||
globals: { | ||
...globals.browser, | ||
...globals.es2022, | ||
}, | ||
parserOptions: { | ||
sourceType: 'module', | ||
}, | ||
}, | ||
plugins: { | ||
'simple-import-sort': simpleImportSort, | ||
}, | ||
rules: { | ||
'simple-import-sort/imports': 'warn', | ||
'simple-import-sort/exports': 'warn', | ||
'import/order': 'off', | ||
}, | ||
}, | ||
{ | ||
files: ['test/**/*.{js,ts}'], | ||
languageOptions: { | ||
parser: babelParser, | ||
globals: { | ||
...jest.environments.globals.globals, | ||
...globals.mocha, | ||
...globals.es2022, | ||
}, | ||
parserOptions: { | ||
sourceType: 'script', | ||
}, | ||
}, | ||
plugins: { | ||
jest, | ||
'jest-dom': jestDOM, | ||
'simple-import-sort': simpleImportSort, | ||
}, | ||
}, | ||
); |
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 |
---|---|---|
|
@@ -80,21 +80,24 @@ | |
}, | ||
"devDependencies": { | ||
"@babel/core": "^7.26.0", | ||
"@babel/eslint-parser": "^7.25.9", | ||
"@babel/preset-env": "^7.26.0", | ||
"@babel/preset-typescript": "^7.26.0", | ||
"@eslint/js": "^9.16.0", | ||
"@types/lodash": "^4.17.13", | ||
"@typescript-eslint/eslint-plugin": "^8.16.0", | ||
"@typescript-eslint/parser": "^8.16.0", | ||
"babel-jest": "^29.7.0", | ||
"chai": "^4.5.0", | ||
"eslint": "^8.57.1", | ||
"eslint": "^9.16.0", | ||
"eslint-config-prettier": "^9.1.0", | ||
"eslint-import-resolver-typescript": "^3.6.3", | ||
"eslint-plugin-import": "^2.31.0", | ||
"eslint-plugin-jest": "^28.9.0", | ||
"eslint-plugin-jest-dom": "^5.5.0", | ||
"eslint-plugin-simple-import-sort": "^12.1.1", | ||
"globals": "^15.13.0", | ||
"jest": "^29.7.0", | ||
"jest-environment-node-single-context": "^29.4.0", | ||
"mocha": "^10.8.2", | ||
"mocha": "^11.0.1", | ||
"npm-run-all": "^4.1.5", | ||
"postcss": "^8.4.49", | ||
"prettier": "^3.4.1", | ||
|
@@ -103,8 +106,9 @@ | |
"sassdoc": "^2.7.4", | ||
"sassdoc-theme-herman": "^6.0.2", | ||
"stylelint": "^16.11.0", | ||
"stylelint-config-standard-scss": "^13.1.0", | ||
"typescript": "^5.7.2" | ||
"stylelint-config-standard-scss": "^14.0.0", | ||
"typescript": "^5.7.2", | ||
"typescript-eslint": "^8.17.0" | ||
}, | ||
"main": "./lib/index.js", | ||
"types": "./lib/index.d.ts", | ||
|
@@ -119,5 +123,5 @@ | |
"sassDir": "./sass/", | ||
"exports": false | ||
}, | ||
"packageManager": "[email protected].0" | ||
"packageManager": "[email protected].3" | ||
} |
Oops, something went wrong.