Develop a Feature
Ship a feature end-to-end: branch, code, test, changeset, PR, and merge.
Prerequisites
- Local environment set up (see Getting Started)
- Familiarity with relevant standards
Steps
1. Create a branch
Start from an up-to-date main branch:
Use Conventional Commits-style branch naming: feat/, fix/, docs/, refactor/, chore/, etc.
2. Make changes
Follow the coding standards:
constonly -- nolet, no mutation- No classes, loops, or
throw - Return
Resulttuples instead of exceptions - Prefer pure functions, composition, and
es-toolkitutilities
See the TypeScript standards and error handling standards for details.
3. Run checks frequently
Run the CI check suite as you work to catch issues early:
Auto-fix formatting and lint issues:
4. Run full checks
Verify your changes pass all checks before committing:
Note: A test runner is not yet configured.
pnpm checkruns typecheck + lint + format.
5. Commit
Use Conventional Commits format:
Format: type(scope): description -- see Commit Standards for types, scopes, and examples.
6. Add a changeset
If the change affects published packages (@zpress/core, @zpress/*), create a changeset:
Follow the prompts to select the package, semver bump type (patch, minor, major), and write a summary. Commit the generated .changeset/*.md file with your other changes.
When to add a changeset:
- New features, bug fixes, or breaking changes to
@zpress/coreor@zpress/*packages
When to skip:
- Docs-only changes, CI updates, internal tooling, contributing docs
Check pending changesets:
7. Push and open a PR
Open a PR against main. Use the same type(scope): description format for the PR title and include these sections in the description:
See Pull Request Standards for the full review and merge process.
CI runs: lint, format, typecheck, test.
8. Address review feedback
Respond to review comments within 24 hours. Make fixup commits and push:
9. Merge
After approval and green CI, use Squash and Merge. The Changesets bot handles versioning and npm publishing on merge to main.
Verification
Before requesting review, confirm:
pnpm check && pnpm buildall pass- PR title follows
type(scope): descriptionformat - Changeset included if the change affects published packages
Troubleshooting
Pre-push hook fails
Issue: git push is blocked by lint or typecheck errors.
Fix:
Fix any remaining typecheck errors, then re-push.
Changeset confusion
Issue: Unsure whether a changeset is needed or what state it is in.
Fix:
This shows all pending changesets and which packages they affect.
Merge conflicts
Issue: PR cannot be merged due to conflicts with main.
Fix: