generator-babel-typescript
v1.0.1
Published
TypeScript package transpiled with Babel using babel-preset-typescript and works with Jest
Downloads
6
Maintainers
Readme
generator-babel-typescript
TypeScript package transpiled with Babel using babel-preset-typescript and works with Jest
Installation
First, install Yeoman and generator-babel-typescript using npm (we assume you have pre-installed node.js).
npm install -g yo
npm install -g generator-babel-typescript
Then generate your new project:
yo babel-typescript
Things I like
- Compile using Babel on a file-by-file basis
- Clean and tidy
- Run test without build
- Single source code build pipeline
Things I don't like
- Type-checking need to run outside of Babel
- Need to run
TSC
just for type-checking, usingconcurrently
- TypeScript output is ugly (multiple empty lines)
- Need to run
- Create declaration files (
*.d.ts
) usingTSC
- May be it is a limitation on Babel on outputting multiple files
- The preset don't read
tsconfig.json
Things don't work
- No source map generated by
@babel/preset-typescript
- It is not taking in
tsconfig.json
- Also not receiving options from
.babelrc
- It is not taking in
License
MIT © William Wong
Contributions
Like us? Star us.
Want to make it better? File us an issue.
Don't like something you see? Submit a pull request.