babel-preset-modern-browsers-stage-1
Babel stage 1 preset for modern browsers.
Installation
npm install --save-dev babel-preset-modern-browsers babel-preset-modern-browsers-stage-1
Usage
Add the following line to your .babelrc
file:
babel-preset-stage-1
Difference with babel-preset-stage-1
.
Today, there is no difference with You can safely use babel-preset-stage-1
instead, because no modern browsers supports the features, as you can see in the compatibility table.
Compatibility Table
Feature | Edge | Firefox | Chrome | Opera | Safari |
---|---|---|---|---|---|
Stage 3 |
|||||
async /await |
14 | No | No | No | No |
↳ transform-async-to-generator | |||||
trailing commas in function | 14 | No | No | No | 10 |
↳ syntax-trailing-function-commas | |||||
Stage 2 |
|||||
Object rest properties | No | No | No | No | No |
Object spread properties | No | No | No | No | No |
↳ transform-object-rest-spread | |||||
Stage 1 |
|||||
class properties | No | No | No | No | No |
↳ babel-plugin-transform-class-properties | |||||
class constructor call | No | No | No | No | No |
↳ babel-plugin-transform-class-constructor-call | |||||
class decorators | No | No | No | No | No |
↳ babel-plugin-transform-decorators |