Skip to content

chore: declare side effects and Node engine range - #19

Merged
bwin merged 2 commits into
devfrom
chore/package-metadata
Nov 3, 2026
Merged

bwin merged 2 commits into
devfrom
chore/package-metadata

Conversation

@bwin

@bwin bwin commented Nov 3, 2026 •

Copy link
Copy Markdown
Owner

Summary

Fixes CONFIRMED-FINDINGS.md items 8 and 9 (package metadata).

  • package.json: adds "sideEffects": ["*.css"] so bundlers can skip the single runtime bundle when none of its exports are used, while keeping the explicit stylesheet import side-effectful.
  • package.json: adds "engines": { "node": ">=20.19.0" }, the lowest Node version supported by the runtime and dev toolchain. Node 22 remains the CI/release environment; it is not a runtime requirement.
  • CHANGELOG.md: records both metadata changes under [Unreleased] / Changed.

Side-effect audit

The built dist/sankey-plus.js imports only React packages, has no stylesheet import, and its top-level statements are declarations/exports plus pure Intl.NumberFormat, forwardRef, effect feature detection and a displayName assignment. It has no DOM reads/writes, listeners, global writes or other externally observable import-time work. The stylesheet is copied separately and imported explicitly by consumers.

Verification

  • npm run format — passed
  • npm run typecheck — passed
  • npm run lint — passed
  • npm test — 152 tests passed
  • npm run build — passed
  • npm run verify:package — passed (packed, fresh consumer, strict NodeNext typecheck, runtime exports and stylesheet)
  • npm pack --dry-run — 12 files; archive contents unchanged apart from package metadata
  • Reviewer independently verified the exact 20.19.0 floor: build, 152 tests, lint and verify:package pass; runtime import/validateGraph/server rendering pass. Webpack 5 and Rollup/node-resolve retain dist/style.css with the actual packed package.

Notes

Browser tests were not run to avoid the shared Playwright port. engines is declarative only; no engine-strict or workflow changes. CI still targets Node 22.

@bwin
bwin merged commit ae04772 into dev Nov 3, 2026
2 checks passed
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