test-npm-deploy-dan

1.0.1 • Public • Published

Publishing to NPM

  • Verify package name is unique in package.json
  • Specify the ["files"] field as an array of files and folders to deploy, typically a post-build "dist" folder or similar
  • Split ["dependencies"] and ["devDependencies]
    • eg. move typescript and @types/ into ["devDependencies]
  • Specify the ["publishConfig"]["access"] field as "public" or "private"
  • Configure the ["bin"] field for the CLI to be used
    • eg. "bin": "dist/index.js" and insert the bin disclaimer in the CLI file (#!/usr/bin/env node)
  • Specify ["scripts"]["prepublishOnly"] field as the script to be ran before publishing, typically to build the project
  • Commit to git if desired, and ensure that .gitignore is configured
  • Finally, run npm publish

Readme

Keywords

none

Package Sidebar

Install

npm i test-npm-deploy-dan

Weekly Downloads

2

Version

1.0.1

License

ISC

Unpacked Size

2.16 kB

Total Files

5

Last publish

Collaborators

  • dannnsoh