package-seed
Default setup for a JavaScript library package
Use
Create a new folder where you want to start a new package or check out a new, empty repository. Run the following from that folder:
npx @wisersolutions/package-seed
This will seed the new package with the default setup. Package description should either be added
manually or using the -d
command-line option.
Note: The seed data expects the package to be hosted under the WiserSolutions
GitHub organization.
If that's not the case, make sure to replace all instances of that label in the seeded sources.
Development
Install
Install dependencies using:
npm install
Develop
After you modify sources, run the following (or set up your IDE to do it for you):
- format the code using
npm run format
- lint it using
npm run lint
- test it using
npm test
and fix the errors, if there are any.
Publish
Publishing is done in two steps:
- Create a new version tag and push it to the repository:
npm version <patch|minor|major> git push --follow-tags
- Build and publish the new version as a npm package:
npm publish --access public