30 lines
691 B
JavaScript
30 lines
691 B
JavaScript
|
const globals = require("globals");
|
||
|
const pluginJs = require("@eslint/js");
|
||
|
const eslintPluginPrettierRecommended = require("eslint-plugin-prettier/recommended");
|
||
|
const jest = require("eslint-plugin-jest");
|
||
|
|
||
|
module.exports = [
|
||
|
{
|
||
|
files: ["**/*.js"],
|
||
|
languageOptions: {
|
||
|
sourceType: "commonjs"
|
||
|
}
|
||
|
},
|
||
|
{
|
||
|
files: ["tests/*.test.js", "tests/**/*.test.js"],
|
||
|
...jest.configs['flat/recommended'],
|
||
|
rules: {
|
||
|
...jest.configs['flat/recommended'].rules,
|
||
|
'jest/prefer-expect-assertions': 'off',
|
||
|
}
|
||
|
},
|
||
|
{
|
||
|
languageOptions: {
|
||
|
globals: {
|
||
|
...globals.node
|
||
|
}
|
||
|
}
|
||
|
},
|
||
|
pluginJs.configs.recommended,
|
||
|
eslintPluginPrettierRecommended
|
||
|
];
|