Skip to content

fix(eslint): correct overrides configuration block structure#1410

Open
themacboy wants to merge 3 commits into
publiclab:mainfrom
themacboy:fix/eslint-config
Open

fix(eslint): correct overrides configuration block structure#1410
themacboy wants to merge 3 commits into
publiclab:mainfrom
themacboy:fix/eslint-config

Conversation

@themacboy

Copy link
Copy Markdown
Contributor

Description

This pull request fixes a syntax and structural error in the global .eslintrc.js configuration file.

Problem:
Any attempt to run npm run build or npx eslint . currently fails with the following fatal error:

Configuration for rule "overrides" is invalid: Severity should be one of the following: 0 = off, 1 = warn, 2 = error (you passed '{ files: [ "examples/js/*.js" ], parserOptions: { sourceType: "module" }}').

This happens because the overrides block was mistakenly nested inside the rules object. ESLint interpreted overrides as a custom rule and crashed when it couldn't find a valid severity level (0, 1, or 2).

Solution:
Moved the overrides block out of the rules object and placed it at the root of the module.exports object, which complies with ESLint's configuration schema.

This fix ensures that CI/CD pipelines and local npm run build scripts can run properly again without immediate fatal configuration errors.

Note: I am themacboy, and I was assisted by an AI agent (Antigravity by Google DeepMind) in debugging and submitting this fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants