An open API service indexing awesome lists of open source software.

https://github.com/compulim/generator-babel-typescript

TypeScript package transpiled with Babel using babel-preset-typescript and works with Jest
https://github.com/compulim/generator-babel-typescript

Last synced: 4 days ago
JSON representation

TypeScript package transpiled with Babel using babel-preset-typescript and works with Jest

Awesome Lists containing this project

README

        

# generator-babel-typescript [![NPM version][npm-image]][npm-url] [![Build Status][travis-image]][travis-url] [![Dependency Status][daviddm-image]][daviddm-url] [![Coverage percentage][coveralls-image]][coveralls-url]
> TypeScript package transpiled with Babel using babel-preset-typescript and works with Jest

## Installation

First, install [Yeoman](http://yeoman.io) and generator-babel-typescript using [npm](https://www.npmjs.com/) (we assume you have pre-installed [node.js](https://nodejs.org/)).

```bash
npm install -g yo
npm install -g generator-babel-typescript
```

Then generate your new project:

```bash
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, using [`concurrently`](https://npmjs.com/package/concurrently)
- TypeScript output is ugly (multiple empty lines)
- Create declaration files (`*.d.ts`) using `TSC`
- 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`](https://github.com/babel/babel/tree/master/packages/babel-preset-typescript)
- It is not taking in `tsconfig.json`
- Also not receiving options from `.babelrc`

## License

MIT © [William Wong](http://compulim.info/)

# Contributions

Like us? [Star](https://github.com/compulim/generator-babel-typescript/stargazers) us.

Want to make it better? [File](https://github.com/compulim/generator-babel-typescript/issues) us an issue.

Don't like something you see? [Submit](https://github.com/compulim/generator-babel-typescript/pulls) a pull request.

[npm-image]: https://badge.fury.io/js/generator-babel-typescript.svg
[npm-url]: https://npmjs.org/package/generator-babel-typescript
[travis-image]: https://travis-ci.org/compulim/generator-babel-typescript.svg?branch=master
[travis-url]: https://travis-ci.org/compulim/generator-babel-typescript
[daviddm-image]: https://david-dm.org/compulim/generator-babel-typescript.svg?theme=shields.io
[daviddm-url]: https://david-dm.org/compulim/generator-babel-typescript
[coveralls-image]: https://coveralls.io/repos/compulim/generator-babel-typescript/badge.svg
[coveralls-url]: https://coveralls.io/r/compulim/generator-babel-typescript