1+ const { defineConfig } = require ( "eslint/config" ) ;
12const js = require ( "@eslint/js" ) ;
23const globals = require ( "globals" ) ;
34const eslintPluginPrettierRecommended = require ( "eslint-plugin-prettier/recommended" ) ;
45
5- /** @type {import('eslint').Linter.FlatConfig[] } */
6- module . exports = [
6+ module . exports = defineConfig ( [
77 js . configs . recommended ,
88 eslintPluginPrettierRecommended ,
99 {
@@ -25,19 +25,12 @@ module.exports = [
2525 fetch : "readonly"
2626 }
2727 } ,
28- // plugins: ["node", "security"],
2928 rules : {
3029 "no-var" : [ "error" ] ,
3130 "no-console" : [ "error" ] ,
3231 "no-unused-vars" : [ "warn" ] ,
33- "no-trailing-spaces" : [ "error" ] ,
34- "security/detect-object-injection" : [ "off" ] ,
35- "security/detect-non-literal-require" : [ "off" ] ,
36- "security/detect-non-literal-fs-filename" : [ "off" ] ,
37- "no-process-exit" : [ "off" ] ,
38- "node/no-unpublished-require" : 0
32+ "no-trailing-spaces" : [ "error" ]
3933 }
40- // ignores: ["benchmark/test.js", "test/typescript/hello-world/out/*.js"]
4134 } ,
4235 {
4336 files : [ "test/**/*.js" ] ,
@@ -53,4 +46,4 @@ module.exports = [
5346 "no-unused-vars" : [ "off" ]
5447 }
5548 }
56- ] ;
49+ ] ) ;
0 commit comments