mirror of
https://github.com/gorhill/uBlock.git
synced 2024-07-08 12:57:57 +02:00
The main nodejs flavor is "npm", which is to be used to lint/test and the publication of an official npm package -- and by design it has dependencies on mocha, eslint, etc. A new flavor "dig" has been created with minimal dependencies and which purpose is to easily allow to write specialized code to investigate local code changes in uBO -- and it's not meant for publication. Consequently, "make nodejs" has been replaced with "make npm", and a new "dig" target has been added to the makefile, to be used for instrumenting local code changes for investigation purpose.
38 lines
1.0 KiB
JSON
38 lines
1.0 KiB
JSON
{
|
|
"env": {
|
|
"es2021": true,
|
|
"node": true
|
|
},
|
|
"extends": "eslint:recommended",
|
|
"parserOptions": {
|
|
"ecmaVersion": 12,
|
|
"sourceType": "module"
|
|
},
|
|
"rules": {
|
|
"eqeqeq": [ "warn", "always" ],
|
|
"indent": [
|
|
"warn",
|
|
4,
|
|
{
|
|
"ArrayExpression": "first",
|
|
"CallExpression": { "arguments": "first" },
|
|
"MemberExpression": "off",
|
|
"ObjectExpression": "off",
|
|
"ignoreComments": true,
|
|
"ignoredNodes": [
|
|
"AssignmentExpression:has(Literal)"
|
|
]
|
|
}
|
|
],
|
|
"getter-return": "off",
|
|
"no-control-regex": "off",
|
|
"no-empty": [ "error", { "allowEmptyCatch": true } ],
|
|
"no-promise-executor-return": [ "error" ],
|
|
"no-template-curly-in-string": [ "error" ],
|
|
"no-unreachable-loop": [ "error" ],
|
|
"no-useless-backreference": [ "error" ],
|
|
"no-useless-escape": "off",
|
|
"require-atomic-updates": [ "warn" ]
|
|
}
|
|
}
|