Skip to content

fix(deps): replace @bigcommerce/handlebars-v4 with npm alias - #407

Merged
jairo-bc merged 1 commit into
masterfrom
jairopanduro/ltrac-993-deprecate-handlebars-v4
Jul 28, 2026
Merged

fix(deps): replace @bigcommerce/handlebars-v4 with npm alias#407
jairo-bc merged 1 commit into
masterfrom
jairopanduro/ltrac-993-deprecate-handlebars-v4

Conversation

@jairo-bc

@jairo-bc jairo-bc commented Jul 28, 2026

Copy link
Copy Markdown
Contributor

Jira: TRAC-961 (LTRAC-993)

What? Why?

  • Replace the @bigcommerce/handlebars-v4 wrapper dependency with an npm alias: handlebars-v4handlebars@4.7.9 (same version the wrapper pinned).
  • The wrapper package existed only to load Handlebars v3 and v4 side by side under distinct names. Modern npm alias support (npm:handlebars@4) does this with no separately published package — same pattern already used for v3 in stencil-renderer-worker.
  • Runtime now imports the handlebars-v4/runtime.js subpath. The bare handlebars export has no .runtime property; only the old wrapper added it.
  • First step toward deprecating @bigcommerce/handlebars-v4 (this is a published dep of the worker / bundle-service, so it must release first).

How was it tested?

  • npm test — 888 tests pass (parity with pre-change baseline).
  • npm run lint — clean.
  • Verified alias resolves: require('handlebars-v4').VERSION === '4.7.9' and handlebars-v4/runtime.js template fn present; @bigcommerce/handlebars-v4 absent from node_modules.

Drop the @bigcommerce/handlebars-v4 wrapper dependency in favor of an npm
alias (handlebars-v4 -> handlebars@4.7.9). Modern npm tooling supports
aliases, so a separately published package is no longer needed to load
handlebars v3 and v4 side by side. Publishing this as a release removes
the wrapper from consumers' transitive dependency tree.

Runtime is imported via the handlebars-v4/runtime.js subpath since the
bare handlebars export has no .runtime property.

Refs TRAC-961
@jairo-bc jairo-bc changed the title TRAC-961: Deprecate @bigcommerce/handlebars-v4 via npm alias fix(deps): replace @bigcommerce/handlebars-v4 with npm alias Jul 28, 2026
@jairo-bc jairo-bc closed this Jul 28, 2026
@jairo-bc jairo-bc reopened this Jul 28, 2026
@jairo-bc
jairo-bc marked this pull request as ready for review July 28, 2026 16:13
@jairo-bc
jairo-bc merged commit 2bc3f6b into master Jul 28, 2026
6 of 18 checks passed
@github-actions

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 6.6.3 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants