Welcome to your new npm module template! 🎉 Here’s a quick guide to get started.
/src: Source codeindex.ts: Entry pointstarter_example.ts: Example functionstypes.ts: Type definitions
package.json: Project metadata and scriptstsconfig.json: TypeScript configurationtsup.config.ts: Build configuration
-
Edit
src/starter_example.ts
Modify or add functions as needed. -
Update
src/types.ts
Define or change types for your module. -
Configure
src/index.ts
Export functions and types from this file. -
Update
package.json
Set your module’s name, description, and other details. -
Build Your Module
Runnpm run buildto compile the TypeScript code.
- Login to npm
If you haven’t logged in yet, run:npm login
- Publish to npm
npm publish
Happy coding! 🚀