-
Notifications
You must be signed in to change notification settings - Fork 8
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
828a233
commit 62b6c78
Showing
6 changed files
with
85 additions
and
64 deletions.
There are no files selected for viewing
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 |
---|---|---|
@@ -1,10 +1,14 @@ | ||
# Dependencies | ||
node_modules/ | ||
package-lock.json | ||
bun.lockb | ||
|
||
# Code Coverage | ||
.nyc_output/ | ||
coverage/ | ||
|
||
# Build | ||
dist/ | ||
|
||
# Mac files | ||
.DS_Store |
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,61 @@ | ||
import eslint from '@eslint/js'; | ||
import tseslint from 'typescript-eslint'; | ||
import eslintPluginEslintPlugin from 'eslint-plugin-eslint-plugin'; | ||
import importPlugin from 'eslint-plugin-import'; | ||
import comments from '@eslint-community/eslint-plugin-eslint-comments/configs'; | ||
import unicornPlugin from 'eslint-plugin-unicorn'; | ||
import babelParser from '@babel/eslint-parser'; | ||
import globals from 'globals'; | ||
|
||
/** @type {import('eslint').Linter.FlatConfig[] | import('eslint').Linter.Config} */ | ||
export default [ | ||
...[ | ||
eslint.configs.recommended, | ||
eslintPluginEslintPlugin.configs['flat/recommended'], | ||
importPlugin.configs.typescript, | ||
comments.recommended, | ||
unicornPlugin.configs['flat/recommended'] | ||
].map((config) => ({ | ||
...config, | ||
ignores: ['dist/**/*', 'coverage/**/*'] | ||
})), | ||
|
||
{ | ||
ignores: ['dist/**/*', 'coverage/**/*'], | ||
languageOptions: { | ||
parser: babelParser, | ||
parserOptions: { | ||
requireConfigFile: false, | ||
ecmaVersion: 2023 | ||
}, | ||
globals: { | ||
...globals.node | ||
} | ||
}, | ||
rules: { | ||
'eslint-plugin/test-case-property-ordering': 'error', | ||
'eslint-plugin/test-case-shorthand-strings': 'error', | ||
'unicorn/prefer-module': 'off', | ||
'unicorn/filename-case': 'off', | ||
'unicorn/prevent-abbreviations': 'off', | ||
'unicorn/no-array-reduce': 'off', | ||
'unicorn/no-nested-ternary': 'off', | ||
'unicorn/prefer-array-find': 'error', | ||
'unicorn/no-null': 'off', | ||
'unicorn/prefer-at': 'off', | ||
'@eslint-community/eslint-comments/no-unused-disable': 'error' | ||
} | ||
}, | ||
...tseslint.config(...tseslint.configs.recommended).flatMap((config) => ({ | ||
...config, | ||
files: ['**/*.ts'] | ||
})), | ||
{ | ||
files: ['tests/**/*.ts'], | ||
languageOptions: { | ||
globals: { | ||
...globals.mocha | ||
} | ||
} | ||
} | ||
]; |
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
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