Skip to content

Latest commit

 

History

History
69 lines (44 loc) · 2.36 KB

README.md

File metadata and controls

69 lines (44 loc) · 2.36 KB

create-tslibs

One stop TypeScript libraries and applications boilerplate generator

IMPORTANT: this script will automatically install pnpm and np globally

Quick Start

Following are the boilerplate option that are available:

  • tslib
  • express (coming soon)
  • styled-theme (coming soon)

replace the option as above to following command:

npx create-tslibs --option=tslib --folder=your-lib-name

# --folder will be your application / library name

PNPM

Instead of using npm, we will be using pnpm, publishing to npm for your packages will be using np, since np is not supported for pnpm hence publish.sh will ensure pnpm i run before np running

tslib

This is a TSDX Extension setup is meant for developing libraries (not apps!) that can be published to NPM. If you’re looking to build a Node app, you could use ts-node-dev, plain ts-node, or simple tsc.

Why this extension?

  1. Inclusive of scripts to generate flow types

  2. Inclusive of scripts to generate multiple modules

  3. Setup for airbnb standard (and remove conflicting linting plugins)

Development Platform:

This tool is designed for VS Code platform.

Hence I suggest using VS Code as IDE:

The templates are already setup with vscode settings for auto format.

Ensure the following plugins are enabled:

Optional but Recommended:

Publishing to NPM

Recommend using np.

Important Note: run npm publish for initial publish before running np commands You may run into the following issue:

npm access 2fa-required create-tslibs
npm ERR! code E400

Happy Coding