Add Babel Typecheck #36
Comments
Hi, I think is off topic. But When using "piping" + "babel/register" in my project, I think that is because piping "hot" reloading and babel slow compilation? |
0.5 to 1 second is considered fast, for restarting node server-side :) "babel/register" allows us to write modern Javascript (ES5/6/7) and Babel Typecheck will allow static + runtime type checking, which prevents an entire class of bugs. So it's worth it. But you can turn it off. Also, perhaps I should bring back the production build for the server, so Babel-transformations are pre-compiled for production. |
@ericfong Do you think webpack hot-loading for the server (https://github.com/webpack/hot-node-example) would be a faster solution? |
The problem of "piping" + "babel/register": If webpack way: Personally, I prefer faster. By the way, I use babel for jsx only. I am using iojs 2.0. |
I'll have to experiment with server-side HMR. Never done that before. If you have the time, a Pull Request is welcome :) |
On-topic: I added Babel Typecheck plugin. It works quite well for regular functions et cetera but unfortunately doesn't support some ES6 syntax (class methods) yet. |
https://github.com/codemix/babel-plugin-typecheck
The text was updated successfully, but these errors were encountered: