Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move to flat ESLint config #4634

Merged
merged 5 commits into from
Apr 19, 2024
Merged

Move to flat ESLint config #4634

merged 5 commits into from
Apr 19, 2024

Conversation

briangregoryholmes
Copy link
Contributor

@briangregoryholmes briangregoryholmes commented Apr 17, 2024

This PR moves our ESLint configuration to the new flat config format, partly in preparation for ESLint v9 and partly to resolve a few issues with our monorepo setup. Legacy config versions are being deprecated.

To trigger linting across all repos, it changes all rel="noreferrer" attributes to the correct rel="noreferrer noopener and adds a key to the each block in web-auth's Auth component.

To enable the ESLint VSCode extension, you'll need to either install the latest prerelease in the marketplace or turn on eslint.experimental.useFlatConfig, see: microsoft/vscode-eslint#1644

Motivation: The use of __dirname in the current configuration does not correctly reference the corresponding tsconfig.json for each project, which is at least one of the issues causing false positive ESLint warnings. The options to solve that are either move to the new flat config or have an additional ESLint configuration per repo.

@briangregoryholmes briangregoryholmes self-assigned this Apr 17, 2024
@briangregoryholmes briangregoryholmes requested review from ericpgreen2 and removed request for ericpgreen2 April 17, 2024 14:08
@briangregoryholmes briangregoryholmes marked this pull request as draft April 17, 2024 14:11
@briangregoryholmes briangregoryholmes changed the title Chore: upgrade eslint version Move to flat ESLint config Apr 17, 2024
@briangregoryholmes briangregoryholmes marked this pull request as ready for review April 17, 2024 20:34
Copy link
Contributor

@ericpgreen2 ericpgreen2 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good to me.

@briangregoryholmes briangregoryholmes merged commit 3b80690 into main Apr 19, 2024
4 checks passed
@briangregoryholmes briangregoryholmes deleted the bgh/eslint branch April 19, 2024 15:06
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