react-scripts
Version:
Configuration and scripts for Create React App.
51 lines (37 loc) • 842 B
Markdown
"use strict";` directive to the top of your files if it is not there
already.
> This plugin may be enabled via `babel-plugin-transform-es2015-modules-commonjs`.
> If you wish to disable it you can either turn `strict` off or pass
> `strictMode: false` as an option to the commonjs transform.
```sh
$ npm install babel-plugin-transform-strict-mode
```
**.babelrc**
```js
// without options
{
"plugins": ["transform-strict-mode"]
}
// with options
{
"plugins": [
["transform-strict-mode", {
"strict": true
}]
]
}
```
```sh
$ babel --plugins transform-strict-mode script.js
```
```javascript
require("babel-core").transform("code", {
plugins: ["transform-strict-mode"]
});
```
Add the `