Skip to content

northerneyes/babel-7-typescript

Repository files navigation

Typescript + Babel 7 with webpack hmr and maximum type safety

Example TypeScript project built on top of new Babel 7 features. Includes React 16, webpack + HMR + typescript server, maximum type safety both by compiler and tslint, prettier + git hook. Since the TypeScript compiler is no longer required to compile sources you can keep your existing Babel pipeline and instead rely on editor-based type-checking or tsc.

Installation

git clone https://github.com/northerneyes/babel-7-typescript.git && cd babel-7-typescript
yarn install
yarn build:dll
yarn dev
yarn typecheck
yarn lint

If you are using VSCode, do not use default tslint extension vscode-tslint and disable it, this project uses tslint-language-service

Configure vscode

You need to configure vscode to work with a specific version of typescript from node_modules and it is also required to enable tslint-language-service because we don't use any plugins for that, add the following line to your .vscode settings folder or to your workspace file:

"typescript.tsdk": "./node_modules/typescript/lib"

About

babel-7 + Typescript example

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published