Skip to content

chore(deps): upgrade to TypeScript 6 and pin all dependencies - #497

Merged
gnbm merged 2 commits into
masterfrom
chore/pin-dependencies-latest
Nov 20, 2026
Merged

gnbm merged 2 commits into
masterfrom
chore/pin-dependencies-latest

Conversation

@gnbm

@gnbm gnbm commented Nov 20, 2026 •

Copy link
Copy Markdown
Collaborator

Issue number: N/A (maintenance)


What is the current behavior?

Every dependency uses a ^ range, so a fresh install can resolve different versions than the lockfile author tested. The toolchain is on TypeScript 5.9 and Cypress 15, and several dev tools are behind their latest releases.

What is the new behavior?

  • All dependencies are pinned to exact versions at the newest release that works with the rest of the toolchain.
  • Notable upgrades: typescript 5.9.3 → 6.0.3, cypress 15.19.0 → 16.3.0, @stylistic/eslint-plugin 5.10.0 → 6.0.1, plus minor/patch bumps for Babel, ESLint and plugins, Sass, sass-loader, css-loader, autoprefixer, webpack and webpack-cli.
  • TypeScript 6 migration in tsconfig.json:
    • removed the deprecated baseUrl (no import resolves through it)
    • moduleResolution: "node" (deprecated) → "bundler"
    • explicit "rootDir": ".", because TS 6 no longer infers it when outDir is set. Without it every Cypress spec fails to compile (TS5011). The emitted ts-types/ layout is unchanged.
  • New src/assets.d.ts declares *.scss modules, because TS 6 now type-checks side-effect imports such as import './sass/styles.scss'.

Held back on purpose

Package Pinned Latest Why
typescript 6.0.3 7.0.2 typescript-eslint (via eslint-plugin-import-x) requires typescript <6.1.0
stylelint 17.16.0 18.1.0 stylelint-config-sass-guidelines@13 (its latest) peers stylelint ^17

Does this introduce a breaking change?

  • Yes
  • No

The production bundle (dist/virtual-select.js, .min.js, .min.css) is byte-identical to a build with the previous versions. Only tooling changes.

Other information

Verified locally on Node 24.19 / npm 11.17 after a clean npm ci:

  • typecheck, lint:js, lint:css, build, test:scripts, test:build: all pass
  • npm test (Cypress 16 e2e): 28/28 specs, 420/420 tests pass

Cypress 16 logs a deprecation warning for the default Electron test browser. Nothing breaks yet, but CI should eventually move to -b chrome.

If you run Cypress from a VS Code integrated terminal and it fails with bad option: --smoke-test, VS Code's ELECTRON_RUN_AS_NODE=1 is the cause, not this change. Unset it for the run.

Pin every dependency to an exact version (no ^ ranges) at the newest
release that works with the rest of the toolchain, and add
save-exact=true to .npmrc so future installs stay pinned.

Notable upgrades: typescript 5.9.3 -> 6.0.3, cypress 15.19.0 -> 16.3.0,
@stylistic/eslint-plugin 5.10.0 -> 6.0.1, plus minor/patch bumps for
Babel, ESLint, Sass, webpack and friends.

Held back:
- typescript 7.x: typescript-eslint (via eslint-plugin-import-x)
  requires typescript <6.1.0.
- stylelint 18.x: stylelint-config-sass-guidelines 13 (latest) peers
  stylelint ^17.

TypeScript 6 migration:
- drop the deprecated baseUrl (nothing resolves through it)
- moduleResolution "node" (deprecated) -> "bundler"
- set rootDir "." explicitly; TS 6 no longer infers it when outDir is
  set, which broke Cypress's per-spec ts-loader compile (TS5011).
  Emitted ts-types layout is unchanged.
- declare '*.scss' modules, since TS 6 now checks side-effect imports
  (noUncheckedSideEffectImports).

The production bundle (dist/) is byte-identical before and after.
@github-actions

github-actions Bot commented Nov 20, 2026 •

Copy link
Copy Markdown

PR Test Results — ✅ all checks passed

Check Result Time
Typecheck ✅ 3s
ESLint ✅ 2s
Stylelint ✅ 1s
CI Scripts ✅ 1s
Build ✅ 2s
a11y-aria-label.cy.ts ✅ 10/10 4s
a11y-close-clears-highlight.cy.ts ✅ 7/7 4s
a11y-escape-close.cy.ts ✅ 6/6 1s
a11y-listbox-multiselectable.cy.ts ✅ 3/3 0s
a11y-live-region.cy.ts ✅ 18/18 5s
a11y-reduced-motion.cy.ts ✅ 3/3 1s
a11y-required-error.cy.ts ✅ 20/20 3s
a11y-search-arrow-navigation.cy.ts ✅ 13/13 5s
a11y-select-all.cy.ts ✅ 7/7 3s
a11y-server-search-announcements.cy.ts ✅ 6/6 4s
a11y-target-size.cy.ts ✅ 5/5 2s
build-stylesheet-integrity.cy.ts ✅ 4/4 1s
examples.cy.ts ✅ 219/219 1m13s
observer-listener-lifecycle.cy.ts ✅ 7/7 1s
perf-resize-throttle.cy.ts ✅ 3/3 1s
perf-scroll-aria.cy.ts ✅ 6/6 3s
secure-option-values.cy.ts ✅ 2/2 1s
secure-text-warning.cy.ts ✅ 4/4 0s
security-ampersand-storage.cy.ts ✅ 16/16 3s
security-chrome-label-props.cy.ts ✅ 10/10 1s
security-classnames-xss.cy.ts ✅ 2/2 1s
security-customdata-xss.cy.ts ✅ 2/2 1s
security-global-defaults.cy.ts ✅ 11/11 1s
security-hidden-input-name.cy.ts ✅ 7/7 1s
security-proto-value.cy.ts ✅ 9/9 1s
security-quote-escaping.cy.ts ✅ 12/12 2s
tag-tooltip-overflow.cy.ts ✅ 6/6 11s
timer-cleanup.cy.ts ✅ 2/2 1s

Tested commit: a820a3a · Run #39

save-exact=true is a local preference, not a repo setting; the pinned
versions in package.json are what keep installs reproducible.
@gnbm
gnbm marked this pull request as ready for review November 20, 2026 22:33
@gnbm
gnbm merged commit f68407f into master Nov 20, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant