This repository is a template to build a modern npm module in TypeScript. This is the template we use for our modules at Voctal.
- Bundles the module for both CJS and ESM formats
- Supports tree-shaking
- Generates source maps (
.map) and TypeScript declaration files (d.ts) - Uses the fastest linter: Oxlint
- Uses the fastest formatter: Oxfmt
- Uses one of the fastest bundler: tsdown, powered by Rolldown
- Uses typescript-go for type checking and type-aware linting
- Automated publishing with a GitHub Actions workflow, including npm provenance
Format all files
npm run fmtType check and lint all files
npm run lintBuild the module
npm run buildYou will also need to set the NPM_TOKEN secret on Github Actions.