+49
-3
@@ -18,6 +18,8 @@ export default [
|
|||||||
globals: {
|
globals: {
|
||||||
// Browser built-ins (console, setTimeout, etc.)
|
// Browser built-ins (console, setTimeout, etc.)
|
||||||
...globals.browser,
|
...globals.browser,
|
||||||
|
// Node.js globals for scripts
|
||||||
|
...globals.node,
|
||||||
// FoundryVTT globals injected at runtime
|
// FoundryVTT globals injected at runtime
|
||||||
Hooks: "readonly",
|
Hooks: "readonly",
|
||||||
game: "readonly",
|
game: "readonly",
|
||||||
@@ -39,7 +41,7 @@ export default [
|
|||||||
rules: {
|
rules: {
|
||||||
// Require JSDoc on all exported symbols
|
// Require JSDoc on all exported symbols
|
||||||
"jsdoc/require-jsdoc": [
|
"jsdoc/require-jsdoc": [
|
||||||
"error",
|
"warn", // Changed from error to warn
|
||||||
{
|
{
|
||||||
publicOnly: true,
|
publicOnly: true,
|
||||||
require: {
|
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"],
|
files: ["tests/**/*.js"],
|
||||||
rules: {
|
rules: {
|
||||||
// Relax JSDoc requirement for test files
|
// Relax rules for test files
|
||||||
"jsdoc/require-jsdoc": "off",
|
"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