eslint.config.mjs
Rama main · réplica de lectura del repositorio original.
import { defineConfig } from "eslint/config";
import eslint from '@eslint/js';
import pluginPromise from 'eslint-plugin-promise'
import globals from 'globals';
import ConfusingGlobals from 'confusing-browser-globals';
const config = defineConfig(
{
files: [
'web/js/modules/**/*.js',
],
languageOptions: {
parserOptions: {
projectService: true,
},
globals: {
...globals.browser,
...globals.jquery,
"bootbox": "readonly",
"CKEDITOR": "readonly",
"Sortable": "readonly",
"ClipboardJS": "readonly",
"Isotope": "readonly",
"__t": "readonly",
},
},
extends: [
eslint.configs.recommended,
pluginPromise.configs['flat/recommended'],
],
rules: {
'no-console': 'off',
'no-debugger': 'off',
'no-restricted-globals': ['error', ...ConfusingGlobals],
'no-prototype-builtins': 'off',
'no-unused-vars': 'off',
'promise/no-callback-in-promise': 'off',
/*
'no-empty': 'off',//todo
'no-useless-escape': 'off',//todo
'prefer-const': 'off',//todo
'promise/always-return': 'off',//todo
*/
},
},
);
export default config;