NPM Package Checklist

This post is mostly for me, so I don't have to keep remembering how to make and publish an npm package.

Minimum viable:

package.json needs

  • /bin dir with a .js file that does the following:
import('../dist/index.js').catch(err => {
    console.error(err);
    process.exit(1);
});