All Projects → michowski → ts-init

michowski / ts-init

Licence: MIT license
Minimalist TypeScript package initializer - like `npm init`, but for TS.

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to ts-init

onli-reducer
⚛️ One line reducer. State management without boilerplate.
Stars: ✭ 31 (+14.81%)
Mutual labels:  javascript-library
party-js
A JavaScript library to brighten up your user's site experience with visual effects!
Stars: ✭ 858 (+3077.78%)
Mutual labels:  javascript-library
Kursor
Cursor style with javascript and css
Stars: ✭ 140 (+418.52%)
Mutual labels:  javascript-library
jackson-js
JavaScript object serialization and deserialization library using decorators. It supports also advanced Object concepts such as polymorphism, Object identity and cyclic objects.
Stars: ✭ 86 (+218.52%)
Mutual labels:  javascript-library
jducers
A js transducers-like implementation using ES9
Stars: ✭ 25 (-7.41%)
Mutual labels:  javascript-library
MLweb
Machine learning and scientific computing (linear algebra, statistics, optimization) javascript libraries, with an online lab.
Stars: ✭ 85 (+214.81%)
Mutual labels:  javascript-library
imtool
🖼️ Client-side canvas-based image manipulation library.
Stars: ✭ 38 (+40.74%)
Mutual labels:  javascript-library
ctxmenu
Tiny and customizable context menu generator
Stars: ✭ 20 (-25.93%)
Mutual labels:  javascript-library
shikijs
A JavaScript Library for Syntax Highlighting with Awesome themes
Stars: ✭ 21 (-22.22%)
Mutual labels:  javascript-library
mongo-uri-builder
A node.js module to easily create mongodb connection strings using configuration objects
Stars: ✭ 29 (+7.41%)
Mutual labels:  javascript-library
sane-reports
Reports library that will keep you sane and not pulling your hair out
Stars: ✭ 47 (+74.07%)
Mutual labels:  javascript-library
ReactNativeWorkshop
Demo project using React Native technology to create a simple iOS app to find music in iTunes
Stars: ✭ 55 (+103.7%)
Mutual labels:  javascript-library
groucho
Know all your users. Scalable front-end (anon) personalization & attribution
Stars: ✭ 31 (+14.81%)
Mutual labels:  javascript-library
tomloprodModal
tomloprodModal is a configurable pure javascript library to create responsive and minimalist modal windows with no dependencies.
Stars: ✭ 17 (-37.04%)
Mutual labels:  javascript-library
animeflv
Animeflv is a custom API that has the entire catalog of the animeflv.net website. You can enjoy all the content with subtitles in Spanish and the latest in the world of anime for free.
Stars: ✭ 37 (+37.04%)
Mutual labels:  javascript-library
discord.js-Moderation-Bot
.Learning how to code in the library discord.js
Stars: ✭ 57 (+111.11%)
Mutual labels:  javascript-library
w-components
JavaScript library based on Web Components.
Stars: ✭ 17 (-37.04%)
Mutual labels:  javascript-library
Mei.js
a minimal, simple and helpful library for you
Stars: ✭ 15 (-44.44%)
Mutual labels:  javascript-library
FilterInputJs
Tiny and Powerful Library for limit an entry (text box,input) as number,string or more...
Stars: ✭ 37 (+37.04%)
Mutual labels:  javascript-library
enterprise
Enterprise-grade component library for the Infor Design System
Stars: ✭ 117 (+333.33%)
Mutual labels:  javascript-library

ts init

Minimalist TypeScript package initializer - like npm init, but for TS.

Install globally:

npm i -g ts-init

From now, whenever you want to create a new TypeScript project, just run:

npm init
ts-init

What does it actually do? Well, not a lot! It will:

  1. Install dev dependencies: typescript, ts-node and rimraf (for cross-platform rm -rf).
  2. Create npm scripts to build your project with TS compiler and run it with ts-node. Build files will be also properly declared in your package.json and added to .gitignore.
  3. Create a minimalist tsconfig.json file with sane defaults: ES6 with the following flags set to true: alwaysStrict, strictNullChecks, noImplicitAny.

Scripts

  • npm run build - build your project
  • npm run ts - run your project with ts-node

Project structure

  • src/ - your source files, must contain index.ts file.
  • test/ - your test files
  • es/ - ES6 build using ES modules
  • lib/ - ES5 build using CommonJS (npm) modules. This directory contains *.d.ts declaration files too.

Motivation

Almost every JavaScript library should be written in TypeScript.

This project is meant to provide everything you need in order to create an npm library (and potentially any other JS project) with modern TypeScript compiler. This way you can use modern ES6 features and static types without any cost.

In the same time, it tries not to force you to use something which is just an opinionated tool. It doesn't include a linter, testing library like Jest or some heavy TS configuration. Everything is kept as minimal as it's possible.

License

MIT

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].