代码拉取完成,页面将自动刷新
"use strict";
const path = require("path");
const rulesDirPlugin = require("eslint-plugin-rulesdir");
rulesDirPlugin.RULES_DIR = path.join(__dirname, "tools/internal-rules");
module.exports = {
root: true,
plugins: [
"eslint-plugin",
"rulesdir"
],
extends: [
"./packages/eslint-config-eslint/default.yml",
"plugin:eslint-plugin/recommended"
],
rules: {
"eslint-plugin/consistent-output": "error",
"eslint-plugin/no-deprecated-context-methods": "error",
"eslint-plugin/prefer-output-null": "error",
"eslint-plugin/prefer-placeholders": "error",
"eslint-plugin/report-message-format": ["error", "[^a-z].*\\.$"],
"eslint-plugin/test-case-property-ordering": "error",
"eslint-plugin/test-case-shorthand-strings": "error",
"rulesdir/multiline-comment-style": "error",
"rulesdir/no-useless-catch": "error"
},
overrides: [
{
files: ["lib/rules/*", "tools/internal-rules/*"],
rules: {
"rulesdir/no-invalid-meta": "error",
"rulesdir/consistent-docs-description": "error"
/*
* TODO: enable it when all the rules using meta.messages
* "rulesdir/consistent-meta-messages": "error"
*/
}
}, {
files: ["lib/rules/*"],
rules: {
"rulesdir/consistent-docs-url": "error"
}
}, {
files: ["tests/**/*"],
env: { mocha: true },
rules: {
"no-restricted-syntax": ["error", {
selector: "CallExpression[callee.object.name='assert'][callee.property.name='doesNotThrow']",
message: "`assert.doesNotThrow()` should be replaced with a comment next to the code."
}]
}
}
]
};
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。