-
Notifications
You must be signed in to change notification settings - Fork 0
/
.babelrc.js
31 lines (28 loc) · 856 Bytes
/
.babelrc.js
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
const presets = [
"@babel/preset-react",
["@babel/preset-env", {
"targets": {
"node": "current"
},
}]
];
const plugins = ["@babel/plugin-proposal-class-properties"];
if (process.env.NODE_ENV !== "test") {
plugins.push([
"babel-plugin-transform-imports",
{
"@material-ui/core": {
// Use "transform: "@material-ui/core/${member}"," if your bundler does not support ES modules
"transform": "@material-ui/core/esm/${member}",
"preventFullImport": true
},
"@material-ui/icons": {
// Use "transform: "@material-ui/icons/${member}"," if your bundler does not support ES modules
"transform": "@material-ui/icons/esm/${member}",
"preventFullImport": true
}
}
]);
};
module.exports = { presets, plugins, "sourceMaps": "inline",
"retainLines": true };