ts-library-template

The idea behind this project is to provide a ready-to-use base for writing a library or end project in TypeScript, with all the tools needed without days wasted on Googling random error messages produced by TS/JS ecosystem hell.


Keywords
cjs, commonjs, compatibility, esm, esmodules, generator, mjs, npm, npm-package, template, typescript
License
MIT
Install
npm install ts-library-template@3.0.0

Documentation

A template for writing next awesome TypeScript library/project.

The idea

The idea behind this project is to provide a ready-to-use base for writing a library or end project in TypeScript, with all the tools needed without days wasted on Googling random error messages produced by TS/JS ecosystem hell.

See also JS-only, previous project: js-library-template. This project should replace it.

Usage

Install ts-library-template globally.

Create new library:

  • tslib <dirname> and answer some questions to create your project.

Upgrade library after upgrading ts-library-template:

  • tslib <dirname> and maybe accept upgrade if needed.

Upgrades are not always fully compatible, especially if you change some configuration, everything should be however easy to fix.

Upgrade existing non-React library to React library:

  • tslib <dirname> --jsx

License

MIT