+49
-3
@@ -18,6 +18,8 @@ export default [
|
||||
globals: {
|
||||
// Browser built-ins (console, setTimeout, etc.)
|
||||
...globals.browser,
|
||||
// Node.js globals for scripts
|
||||
...globals.node,
|
||||
// FoundryVTT globals injected at runtime
|
||||
Hooks: "readonly",
|
||||
game: "readonly",
|
||||
@@ -39,7 +41,7 @@ export default [
|
||||
rules: {
|
||||
// Require JSDoc on all exported symbols
|
||||
"jsdoc/require-jsdoc": [
|
||||
"error",
|
||||
"warn", // Changed from error to warn
|
||||
{
|
||||
publicOnly: true,
|
||||
require: {
|
||||
@@ -117,16 +119,60 @@ export default [
|
||||
],
|
||||
},
|
||||
],
|
||||
// Allow unused variables starting with underscore
|
||||
"no-unused-vars": [
|
||||
"warn", // Changed from error to warn
|
||||
{
|
||||
argsIgnorePattern: "^_",
|
||||
varsIgnorePattern: "^_",
|
||||
caughtErrorsIgnorePattern: "^_",
|
||||
},
|
||||
],
|
||||
// Allow empty catch blocks with underscore
|
||||
"no-empty": [
|
||||
"error",
|
||||
{
|
||||
allowEmptyCatch: true,
|
||||
},
|
||||
],
|
||||
},
|
||||
},
|
||||
{
|
||||
files: ["tests/**/*.js"],
|
||||
rules: {
|
||||
// Relax JSDoc requirement for test files
|
||||
// Relax rules for test files
|
||||
"jsdoc/require-jsdoc": "off",
|
||||
"no-unused-vars": "warn",
|
||||
"no-empty": "warn",
|
||||
},
|
||||
},
|
||||
{
|
||||
ignores: ["dist/", "node_modules/", "*.zip"],
|
||||
files: ["scripts/**/*.mjs"],
|
||||
languageOptions: {
|
||||
globals: {
|
||||
// Ensure Node.js globals are available in ESM script files
|
||||
...globals.node,
|
||||
},
|
||||
},
|
||||
rules: {
|
||||
// Allow unused imports in scripts
|
||||
"no-unused-vars": "warn",
|
||||
"no-empty": "warn",
|
||||
},
|
||||
},
|
||||
{
|
||||
ignores: [
|
||||
"dist/",
|
||||
"node_modules/",
|
||||
"*.zip",
|
||||
"_bmad-output/",
|
||||
"test-results/",
|
||||
"tests/e2e/_bmad-output/",
|
||||
"tests/e2e/fixtures/",
|
||||
"tests/fixtures/",
|
||||
"tests/helpers/",
|
||||
"**/trace/",
|
||||
"**/assets/codeMirrorModule-*.js",
|
||||
],
|
||||
},
|
||||
];
|
||||
|
||||
Reference in New Issue
Block a user