generated from andreidmt/tpl-react-lib
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.babelrc
31 lines (26 loc) · 1.1 KB
/
.babelrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
{
"presets": [
// Use the latest JavaScript without needing to micromanage which syntax
// transforms and browser polyfills are needed by your target environment.
//
// Uses .browserslistrc to specify target environments.
"@babel/preset-env",
// Load React specific plugins
"@babel/preset-react"
],
"plugins": [
// Babel uses very small helpers for common functions such as _extend. By
// default this will be added to every file that requires it. This
// duplication is sometimes unnecessary, especially when your application
// is spread out over multiple files.
"@babel/plugin-transform-runtime",
// Can speed up reconciliation and reduce garbage collection pressure
// by hoisting React elements to the highest possible scope,
// preventing multiple unnecessary reinstantiations.
"@babel/plugin-transform-react-constant-elements",
// Remove data-test-id attributes from your production builds.
"babel-plugin-jsx-remove-data-test-id",
// Add displayName to React.createClass calls
"@babel/plugin-transform-react-display-name"
]
}