As you might know, Babel is a JS transpiler that is popular for its ability to turn ES6 or ES7 into the code that can run on your browsers and devices. As most of them still support older standards. With Babel, you can write your code in the latest conventions and not worry about compatibility errors. It’s been 3 years from the las Babel update – Babel 6. And now we want you to meet Babel 7 huge release!
Here are some of the major updates for Babel 7:
- The new upgrade tool called
babel-upgrade. This tool will automatically make any upgrade changes in the
- JS configuration files:
babel.config.js(not a replacement for
.babelrc), a great addition that can be useful for certain use-cases.
- Overrides in Babel will allow you to specify different configurations per glob.
- New Babel itself is faster so it should take less time to build. Hurray!
- Babel is now able to parse TypeScript syntax using a new package called
- Automatic Polyfilling! This will allow us to use other features like
Symbolsin environents that don’t even support them. More than just change the syntax of the code. It can implement built-in functions and objects.
@babel/corepackage also has a new option called
callerthat will allow us to pass any metadata to our presets and plugins.
Find out more about these updated and features in the official Babel recourse!