Skip to content

Update npm dependencies and tooling config - #223

Merged
jsnmrs merged 3 commits into
mainfrom
deps
Oct 18, 2026
Merged

jsnmrs merged 3 commits into
mainfrom
deps

Conversation

@jsnmrs

@jsnmrs jsnmrs commented Oct 18, 2026

Copy link
Copy Markdown
Contributor

Summary

Major-version bumps for the npm toolchain, plus the config changes those versions require so the pre-commit hook and npm test pass again.

Dependency bumps (package.json): ESLint 8 to 10, Prettier 2 to 3, pretty-quick 3 to 4, husky 8 to 9, stylelint 15 to 17, stylelint-scss 5 to 7, stylelint-config-standard 33 to 40, stylelint-config-standard-scss 9 to 17, and the related stylelint plugins.

Husky 9. The pre-commit hook drops the deprecated husky.sh header, and the prepare script uses the v9 form.

Stylelint 17. The stylelint-scss rule at-import-no-partial-leading-underscore was renamed to load-no-partial-leading-underscore. The new config also flags two deprecated CSS values, resolved as follows:

  • word-break: break-word becomes overflow-wrap: anywhere in table cells and the %u-word-wrap placeholder.
  • The clip fallback is removed from %u-visually-hidden. clip-path: inset(100%) stays, and every browser in the current browserslist supports it.
  • Stylelint's own autofixes are included: word-wrap to overflow-wrap, grid-gap to gap, and rgba() to rgb().

scss-to-json replaced. @crocsx/scss-to-json is unmaintained and uses the legacy Sass JS API, which warns on every run. scripts/tokenize.js reads the variables partial through the modern compileString API and emits the same JSON keys in the same order. Values are no longer minified, so the font stack gains spaces after commas and the border widths gain a leading zero. sass is now a direct devDependency.

ESLint 10. .eslintrc is migrated to eslint.config.js with the same rules: recommended core rules, no-unsanitized DOM rules, Prettier as a lint rule, and the xss location-href rule. Adds @eslint/js and globals, which ESLint no longer bundles. The prettier and eslint npm scripts now also cover scripts/*.js.

Not changed

Dart Sass warns that @import is deprecated. The site builds with the github-pages gem, which pins Ruby Sass 3.7 and has no @use support, so the partials keep @import until the build moves off that gem.

Testing

  • npm run stylelint, npm run js, and the pre-commit hook all exit 0 with no deprecation output.
  • The stylesheet compiles with Dart Sass. bundle exec jekyll build could not be run locally because the github-pages gems are not installed under the current Ruby; CI covers that step.

Remove the deprecated husky.sh header from the pre-commit hook and switch the prepare script to the v9 form. Rename the stylelint-scss rule to load-no-partial-leading-underscore. Replace deprecated CSS flagged by the new config: word-break: break-word becomes overflow-wrap: anywhere, the clip fallback is dropped from the visually-hidden placeholder, and stylelint's autofixes for word-wrap, grid-gap, and rgba() are included.
The @crocsx/scss-to-json package is unmaintained and calls the legacy Sass JS API, which prints a deprecation warning on every run. The new scripts/tokenize.js reads the variables partial through the modern compileString API and emits the same JSON keys in the same order. Values are no longer minified, so the font stack keeps spaces after commas and the border widths keep their leading zero. Adds sass as a direct devDependency.
ESLint 10 no longer reads .eslintrc, so eslint.config.js carries the same setup: recommended core rules, no-unsanitized DOM rules, Prettier as a lint rule, and the xss location-href rule. Browser scripts in assets keep script mode and browser globals; build scripts in scripts get CommonJS mode and Node globals. Adds @eslint/js and globals, which ESLint no longer bundles, and widens the prettier and eslint npm scripts to cover scripts/*.js. Prettier 3 adds two trailing commas to navigation.js.
@jsnmrs
jsnmrs merged commit a67ebdb into main Oct 18, 2026
1 check passed
@jsnmrs
jsnmrs deleted the deps branch October 18, 2026 22:37
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.

1 participant