import js from '@eslint/js'
import { defineFlatConfig } from 'eslint-define-config'
import jsdoc from 'eslint-plugin-jsdoc'
-import nodePlugin from 'eslint-plugin-n'
import simpleImportSort from 'eslint-plugin-simple-import-sort'
import globals from 'globals'
-import neostandard from 'neostandard'
-// eslint-disable-next-line n/no-extraneous-import
-import tseslint from 'typescript-eslint'
+import neostandard, { plugins } from 'neostandard'
export default defineFlatConfig([
{
},
cspellConfigs.recommended,
js.configs.recommended,
- ...nodePlugin.configs['flat/mixed-esm-and-cjs'],
+ plugins.promise.configs['flat/recommended'],
+ ...plugins.n.configs['flat/mixed-esm-and-cjs'],
jsdoc.configs['flat/recommended-typescript'],
{
rules: {
- 'jsdoc/check-tag-names': ['warn', { typed: true, definedTags: ['defaultValue', 'experimental', 'typeParam'] }],
+ 'jsdoc/check-tag-names': [
+ 'warn',
+ {
+ typed: true,
+ definedTags: ['defaultValue', 'experimental', 'typeParam'],
+ },
+ ],
},
},
- ...tseslint.config(
- ...tseslint.configs.strictTypeChecked,
- ...tseslint.configs.stylisticTypeChecked
+ ...plugins['typescript-eslint'].config(
+ ...plugins['typescript-eslint'].configs.strictTypeChecked,
+ ...plugins['typescript-eslint'].configs.stylisticTypeChecked
),
...neostandard({
ts: true,
globals: {
- ...globals.node,
...globals.mocha,
},
}),
'Quadflieg',
'neostandard',
'poolifier',
- 'tseslint',
],
},
},
},
{
files: ['**/*.js', '**/*.mjs', '**/*.cjs'],
- ...tseslint.configs.disableTypeChecked,
+ ...plugins['typescript-eslint'].configs.disableTypeChecked,
},
// examples specific configuration
{