3 ms·
Bublé creator here. The obvious big difference is that this supports TypeScript and Flow, which Bublé doesn't. Bublé is designed to compile a subset of ES6+ int
by rich_harris 8y ago
Bublé creator here. The obvious big difference is that this supports TypeScript and Flow, which Bublé doesn't. Bublé is designed to compile a subset of ES6+ into ES5 (the subset of ES6+ that transpiles well without causing bloat, which excludes some features like generators), whereas this seems to be focused on more modern targets.
Technically there are a few interesting differences under the hood, such as Sucrase not wasting time generating a full-blown AST (which Bublé needs to do in order to handle things like block scoping).
Anyway, I won't waffle on any further as I'm sure Alan can explain the differences better — I just wanted to chime in to say that I'm excited about Sucrase. I've written a [Rollup plugin][1] for it, and I'm planning to use it with my TypeScript projects.
[1]: https://github.com/rollup/rollup-plugin-sucrase https://github.com/rollup/rollup-plugin-sucrase