Node >=14 engines claim doesn't hold: shipped bundle fails to parse on Node 14
Author: axisrowCreated Sep 26, 2026Updated Sep 27, 2026
Node >=14 engines claim doesn't hold: the shipped bundle fails to parse on Node 14
package.json declares "engines": { "node": ">=14.0.0" } and the build targets Node 14 (bun build … --target=node --target-version=14), but the shipped dist/ cannot even be loaded by a real Node 14.
Repro (ccstatusline 2.2.30, macOS, Node v14.21.3)
$ printf '{"model":{"id":"claude-sonnet-4-5"}}' | node-v14.21.3-darwin-x64/bin/node dist/ccstatusline.js
file:///…/dist/ccstatusline-wckvcay0.js:15
var cache = isNodeMode ? __toESMCache_node ??= new WeakMap : __toESMCache_esm ??= new WeakMap;
^^^
SyntaxError: Unexpected token '??='
at Loader.moduleStrategy (internal/modules/esm/translators.js:149:18)The failing code is bun's own ESM-interop helper chunk, emitted into the bundle with ??= intact — --target-version=14 does not transpile logical assignment operators (??=/||=/&&=, Node 15+). Since the chunk is imported at startup, the binary exits before rendering anything.
The floor is higher for two more reasons
- The bundle inlines dependencies, and the pinned versions declare much higher floors themselves:
chalk@6→node >=22,[email protected]→node >=20. Even with the syntax issue fixed, nothing on a Node 14 runtime is exercised or guaranteed (ink 6 is required for the TUI). - Observed the same
??=rejection on independent builds (including a--packages=externalvariant), so it is not specific to one bundle layout.
Suggestion
Pick one, whichever matches the project's intent:
- Honest floor (probably cheapest): bump
enginesto>=20(ink's floor) or>=22(chalk's), and drop--target-version=14so the target claim matches reality. Note npm does not hard-enforceenginesby default, so today users on old Node get the SyntaxError above instead of a clear message. - Keep 14: transpile logical assignment operators in the build output and downgrade the bundled dependency set (chalk would need a ≤4-era pin, which conflicts with the current chalk@6 dependency) — significantly more work and a permanent transpile-maintenance burden.
Verified today on current main; happy to send a PR for either direction.
Environment: ccstatusline 2.2.30, macOS (darwin-x64), Node v14.21.3, bun 1.3.13 build.
Source: sirmalloc/ccstatusline