slayerfat / npm-experiments

Nothing to see here, move along

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

npm-experiments

Build Status

Uses this documentation and its inspired by this article.

The feature branches have some experiments on:

  • Basic Typescript (merged)
  • Basic ES5 Javascript
  • Basic ES6 Javascript

This branch setup

The main entry is inside the src folder as main.ts

This process is done in the package.json prepublish script which just calls the compiler.

Thx to tsconfig.json the typescript compiler will output the files into the lib folder.

Local testing without publish

With npm link

cd path/to/package
npm link # should install a global symlink
cd path/to/consumer/
npm link packageName # will create a symlink locally

With npm pack

npm pack then tar -tf packagename-version.tgz

after than u can:

cd path/to/consumer/
npm install ../path/to/package/packagename-version.tgz

Testing

Extracted from This article

ts-node makes all the magic happen.

About

Nothing to see here, move along

License:MIT License


Languages

Language:TypeScript 100.0%