Node 4 and Babel 6 in Harmony
A note for the upgrade from Node 4 and Babel 6
Pun in title intentional
I upgraded a heap of projects I was working on to node 4.2.3 and babel 6.
As I did a quick and dirty upgrade, I kept thinking to myself: doesn’t node 4/5 have pretty good support for es6/2015?
As I was looking around the internet for Hello Kitty Formalwear babel 6 upgrade tips, I came across this package which read my mind.
So if you’re a node 4/5 user, by doing this:
npm install --save-dev babel-preset-es2015-node4
Then changing your .babelrc
to look something like this:
{
"presets": ["es2015-node4"]
}
you’ll get the minimal tranpilation needed to use the latest ES6 features with node 4/5.