Release and Publishing
Resux uses a safe release flow:
- CI runs on every push and pull request.
- npm publishing runs only for version tags (
vX.Y.Z) or published GitHub Releases. - Normal pushes to
maindo not publish.
At the time of this docs update (2026-05-07), npm latest for resuxjs is 0.2.23.
CI workflow
The CI workflow runs:
sh
npm ci
npm run lint --if-present
npm run typecheck
npm run build
npm test
npm run pack:check --if-presentRelease workflow
Before creating a release tag, run the local quality gate:
sh
npm install
npm run typecheck
npm run build
npm test
npm pack --dry-runThen publish through Git tags:
- Update version in
package.json(for example0.2.24). - Commit the release changes.
- Create tag
v0.2.24. - Push commit and tag.
- GitHub Actions validates the tag/version match and publishes to npm.
sh
npm version 0.2.24
git push origin main
git push origin v0.2.24npm auth and provenance
The publish workflow expects:
NPM_TOKENin GitHub repository secrets.id-token: writepermission for npm provenance.
Publishing uses:
sh
npm publish --access public --provenanceSafety checks in workflow
Publish job safeguards:
- Validates the tag format (
vX.Y.Z). - Validates tag version equals
package.jsonversion. - Runs
npm ciandnpm run pack:check. - Skips publish if the package version already exists on npm.