Setup a ts project as following steps:
yarn global add typescript
yarn init
or setting defaults yarn init -yp
tsc --init
The project structure seems like:
¦ package.json
¦ tsconfig.json
¦ tslint.json
¦ yarn.lock
¦
+-dist
¦ index.js
¦
+-src
index.ts