1.0.0 • Published 4 years ago

npm-ts-starter v1.0.0

Weekly downloads
3
License
MIT
Repository
github
Last release
4 years ago

Usage

  1. Clone this repo:

      git clone git@github.com:vriad/npm-ts-starter.git yourpkgname
      cd yourpkgname

    Then create a new repoisitory in your GitHub account and set it up

    rm -rf .git
    git init
    git remote add origin GITHUB_REMOTE_URL
    git add .
    git commit -am "Initial commit"
    git push origin master
  2. In package.json: update "name", "description", "repository", "keywords", "tags", "hompage", and any other relevant fields.

  3. Implement your module! Start writing code in index.ts.
  4. Write tests! See 'tests/sample.ts' for some basic examples. Run your tests with yarn test. This automatically generates a badge like this to display your test coverage: coverage
  5. Write a README. An initial template is below. Find and replace all references to "pkgname" with your package's name and "username" with your GitHub username. Delete this "Meta-README" section before you deploy (everything above the red line).
  6. Install Node (here) if you haven't already. This automatically installs the npm command-line tool to your computer.
  7. Create an npm account through npmjs.com.
  8. Use the npm login command to sign into npm on your computer.
  9. Build your project with yarn build. This transpiles your TyeScript to JavaScript code and writes the output into /lib.
  10. Publish to npm with npm publish.

License npm stars coverage

Table of contents

Installation

To install the latest version:

npm install --save pkgname
yarn add pkgname

TypeScript versions

Compatible with TypeScript 3.2+.

Usage

Write stuff here!

Changelog

versionrelease notes
pkgname@1.0Initial release