ESLint v10 update - #105
Conversation
There was a problem hiding this comment.
Pull request overview
This PR modernizes the project’s tooling by upgrading core dev dependencies (notably ESLint/TypeScript/Astro) and migrating ESLint to the new flat config format, along with a few small config and site tweaks.
Changes:
- Upgraded ESLint to v10 and migrated from
.eslintrc.cjstoeslint.config.js(flat config), adding@eslint/jsandglobals. - Upgraded key dependencies and tightened Node requirements (Volta +
engines), plus refreshed related docs/settings. - Minor adjustments to site layout/script loading and linting rules (HTMLHint accessibility rule enabled).
Reviewed changes
Copilot reviewed 9 out of 10 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
eslint.config.js |
Introduces flat ESLint config for JS/TS/Astro. |
.eslintrc.cjs |
Removes legacy ESLint config. |
package.json |
Upgrades ESLint/TS/Astro and updates Node requirements. |
package-lock.json |
Locks upgraded dependency graph. |
AGENTS.md |
Updates documented project standards/versions. |
.vscode/settings.json |
Updates default formatter extension ID for Prettier. |
.htmlhintrc |
Enables frame-title-require for improved accessibility linting. |
.cspell.json |
Adds htmlhint to the spelling allowlist. |
src/layouts/Layout.astro |
Adjusts Plausible script loading attributes. |
src/scripts/app.js |
Removes unused parameter from editor change handler. |
Comments suppressed due to low confidence (1)
AGENTS.md:12
- The previous guidance included an explicit accessibility requirement (“All HTML must be accessible.”), but that statement is removed here while the repo is also enabling additional accessibility linting rules (e.g.,
frame-title-require). Consider restoring the accessibility requirement (or replacing it with an equivalent statement) so the documented standards remain consistent.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
Code Review
This pull request primarily focuses on upgrading the project's development environment and core dependencies. Key updates include migrating to ESLint v10.2.0 with a new flat configuration file, upgrading Astro to v6.1.3, and updating TypeScript to v5.9.0. The Node.js engine and Volta versions have also been bumped to v22.22.2. Other changes include refining the HTMLHint and CSpell configurations, updating VS Code formatter settings, and performing minor code cleanups in the layout and editor scripts. I have no feedback to provide as there were no review comments.
Add "esbenp" to the cspell custom words to prevent false-positive spelling flags, and disable Trivy validation in the GitHub super-linter workflow (set VALIDATE_TRIVY: false) to skip vulnerability scanning in CI. Files modified: .cspell.json, .github/workflows/super-linter.yml.
This pull request introduces several updates focused on modernizing the project's tooling, updating dependencies, and improving configuration files. The most significant changes are the migration to the new flat ESLint config system, dependency upgrades (notably ESLint, TypeScript, Astro, and Bootstrap), and updates to project documentation and settings to reflect these changes.
Tooling and Linting Configuration Updates:
.eslintrc.cjsto the new flat config system by addingeslint.config.js, which uses the latest ESLint, TypeScript, and Astro plugin configurations. This also introduces theglobalspackage for environment globals. (eslint.config.js[1].eslintrc.cjs[2]esbenp.prettier-vscodeinstead ofprettier.prettier-vscodefor formatting. (.vscode/settings.json.vscode/settings.jsonL3-R3)Dependency and Environment Upgrades:
package.jsonand documentation. (package.json[1]AGENTS.md[2]Documentation and Rule Updates:
AGENTS.md, reflecting new versions for ESLint, Node, and Bootstrap, and clarifying project standards. (AGENTS.mdAGENTS.mdL1-L14)"htmlhint"to the spelling allowlist in.cspell.jsonand enabled theframe-title-requirerule in.htmlhintrcfor improved accessibility linting. (.cspell.json[1].htmlhintrc[2]Minor Code and Behavior Adjustments:
Layout.astroto load asynchronously with lower fetch priority and added theis:inlineattribute. (src/layouts/Layout.astrosrc/layouts/Layout.astroL25-R25)editor.on('change')handler inapp.jsby removing the unused event parameter. (src/scripts/app.jssrc/scripts/app.jsL109-R109)