Change note to English

This commit is contained in:
Qu Yi 2024-11-03 04:01:11 +08:00
parent 5e84d69aee
commit e1dfad9080

View file

@ -4,10 +4,10 @@ import pluginJs from "@eslint/js";
/** @type {import('eslint').Linter.Config[]} */ /** @type {import('eslint').Linter.Config[]} */
export default [ export default [
// 首先引入推荐配置 // First, import the recommended configuration
pluginJs.configs.recommended, pluginJs.configs.recommended,
// 然后覆盖或自定义特定规则 // Then override or customize specific rules
{ {
languageOptions: { languageOptions: {
globals: globals.browser, globals: globals.browser,
@ -15,11 +15,11 @@ export default [
sourceType: "module", sourceType: "module",
}, },
rules: { rules: {
"no-undef": "error", // 禁止使用未声明的变量或函数。 "no-undef": "error", // Disallow the use of undeclared variables or functions.
"semi": ["error", "always"], // 强制在语句末尾使用分号。 "semi": ["error", "always"], // Require the use of semicolons at the end of statements.
"curly": "warn", // 强制使用花括号包裹代码块。 "curly": "warn", // Enforce the use of curly braces around blocks of code.
"no-unused-vars": "off", // 禁用未使用变量的警告。 "no-unused-vars": "off", // Disable warnings for unused variables.
"no-unreachable": "off", // 禁用无法到达代码的警告。 "no-unreachable": "off", // Disable warnings for unreachable code.
}, },
}, },
]; ];