Package template that can get you
99%
quality and33%
maintenance onnpm
- I used this approach personally to publish following packages
- They all got
99
+% quality rating on NPM - Most of them are located on 1st page of npm search by keyword
backend
- Replace package name and package description here and in package.json
- Replace
AlexXanderGrib/package-template
to your repository - Replace
package_template
to your package name - Write some code and cover it with tests
- Write tests and increase coverage. To exclude files with destructive side-effects, you can use following comment
/* istanbul ignore file */
- Everything else is already in this template
- TypeScript support
- Auto build to both ES-Modules and CommonJS
- TS-Jest
- Exports mapping
- Git Hooks
- Remember to run
npm test
before publishing to include coverage files in package and increase quality of your package - PUBLISH USING ONLY NPM. Not doing this will decrease score by 15-25%
Upload 3 versions of your package in 24 hours. You can not get more than 33% maintenance on npm
- Using
npm
npm i package_template
- Using
Yarn
yarn add package_template
- Using
pnpm
pnpm add package_template
import { Example } from "package_template";
const container = new Example(10);
console.log(container);
// Example { value: 10 }