Skip to content

chore: dependency management — chore/dependency-management-2026-05-22#1211

Draft
alexluckett wants to merge 12 commits into
mainfrom
chore/dependency-management-2026-05-22
Draft

chore: dependency management — chore/dependency-management-2026-05-22#1211
alexluckett wants to merge 12 commits into
mainfrom
chore/dependency-management-2026-05-22

Conversation

@alexluckett
Copy link
Copy Markdown
Contributor

Dependency management

Removed (unused)

  • @hapi/catbox — only transitive; @hapi/catbox-memory and @hapi/catbox-redis are the direct imports
  • @hapi/jwt — no references anywhere in codebase
  • accessible-autocomplete — no references
  • atob — no references (native atob available in Node 16+)
  • btoa — no references (native btoa available in Node 16+)
  • date-fns — no references
  • highlight.js — no references
  • liquidjs — no references
  • lodash — no references
  • marked — no references
  • semver — no references
  • @types/atob, @types/btoa, @types/eslint, @types/hapi, @types/hapi__catbox-memory, @types/hapi__cookie, @types/hapi__yar, @types/hoek, @types/lodash, @types/mysql, @types/url-parse, @types/webpack-assets-manifest, @types/wreck — corresponding packages either removed or ship bundled types
  • core-js — no references
  • outdent — no references

Kept: pino-pretty (string-referenced pino transport), babel-plugin-transform-import-meta (used in jest.config.mjs), husky (active pre-commit hook)

Also fixes a pre-existing issue where the active .worktrees/feature/i18n worktree was picked up by ESLint, breaking lint CI. Added .worktrees/** to eslint.config.js global ignores.

Updated (minor/patch)

29 packages updated to latest minor/patch. neostandard pinned at ^0.12.2 (^0.13.0 breaks the import-x plugin). Trivial fix: removed unnecessary type assertion in type-utils.ts flagged by typescript-eslint@^8.59.4.

Major updates — applied (simple, in this PR)

  • @hapi/scooter: ^7 → ^8 — internal dep swap only, API unchanged
  • copy-webpack-plugin: ^13 → ^14 — Node.js minimum version bump only
  • eslint-plugin-jsdoc: ^62 → ^63 — drops Node 20 support only
  • lint-staged: ^16 → ^17 — bug fix release, no API changes
  • proxy-agent: ^6 → ^8 — ESM-only from v8; added proxy-agent and its nested ESM deps to jest.config.mjs transformIgnorePatterns
  • cssnano + cssnano-preset-default: ^7 → ^8 — no config changes required
  • sass-loader: ^16 → ^17 — legacy Sass JS API removed (unused); no changes required
  • webpack-cli: ^6 → ^7 — no breaking API changes

Skipped: chokidar (peer dep conflict with nunjucks@3.2.4 which requires ^3.3.0)

Major updates — stacked PRs

None.

Major updates — deferred (large)

  • jsdom + global-jsdom + @types/jsdom: ^26 → ^29 — jsdom v27+ went ESM-first across its entire dependency tree, requiring migration away from Jest's Babel transform model (e.g. to Vitest). Not suitable for a single PR.
  • govuk-frontend: ^5 → ^6 — template and component architecture changes
  • joi: ^17 → ^18 — validation schema DSL used extensively throughout the app
  • eslint: ^9 → ^10 — plugin ecosystem and config format changes
  • typescript: ^5 → ^6 — type system changes that could cascade across codebase
  • stylelint: ^16 → ^17 — rule renames and config format changes

Removed 11 prod deps (@hapi/catbox, @hapi/jwt, accessible-autocomplete,
atob, btoa, date-fns, highlight.js, liquidjs, lodash, marked, semver)
and 15 dev deps confirmed unused via static analysis.

Kept: pino-pretty (pino transport string ref), babel-plugin-transform-import-meta
(jest.config.mjs), husky (active pre-commit hook).

Also adds .worktrees to eslint globalIgnores — pre-existing issue where the
active feature/i18n worktree was picked up by ESLint, breaking lint CI.
29 packages updated. neostandard pinned at ^0.12.2 (^0.13.0 breaks
import-x plugin). Trivial fix: removed unnecessary type assertion in
type-utils.ts flagged by typescript-eslint@^8.59.4.
v8 is ESM-only. Added proxy-agent and its nested ESM dependencies
(agent-base, https-proxy-agent, http-proxy-agent) to Jest's
transformIgnorePatterns so Babel can process them in tests.
All passed verify with no code changes except proxy-agent v8 (ESM-only):
added proxy-agent, agent-base, https-proxy-agent, http-proxy-agent to
jest.config.mjs transformIgnorePatterns.

jsdom/global-jsdom upgrade (v26 -> v29) reverted — jsdom v27+ went
ESM-first across its entire dep tree, requiring a Jest migration to
handle (deferred as large).
@alexluckett alexluckett marked this pull request as draft May 22, 2026 14:45
@defra/forms-model@3.0.671 tightened FormStatus — status from hapi route
params is string but detailsViewModel now expects FormStatus | undefined.
@sonarqubecloud
Copy link
Copy Markdown

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