Last try of using babel polyfill
This commit is contained in:
parent
2ba7935621
commit
774a447288
2 changed files with 3 additions and 8 deletions
7
.babelrc
7
.babelrc
|
|
@ -1,12 +1,7 @@
|
||||||
{
|
{
|
||||||
"presets": [
|
"presets": [
|
||||||
["@babel/preset-env", {
|
["@babel/preset-env", {
|
||||||
modules: false,
|
modules: false
|
||||||
useBuiltIns: "usage",
|
|
||||||
debug: true,
|
|
||||||
targets: {
|
|
||||||
browsers: ["iOS 5"]
|
|
||||||
}
|
|
||||||
}],
|
}],
|
||||||
"@babel/preset-react",
|
"@babel/preset-react",
|
||||||
"@babel/preset-flow"
|
"@babel/preset-flow"
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,7 @@ const configPath = env => {
|
||||||
|
|
||||||
module.exports = env => ({
|
module.exports = env => ({
|
||||||
entry: {
|
entry: {
|
||||||
main: [configPath(env),
|
main: ["@babel/polyfill", configPath(env),
|
||||||
path.resolve(__dirname, 'src/index.jsx')]
|
path.resolve(__dirname, 'src/index.jsx')]
|
||||||
},
|
},
|
||||||
resolve: {
|
resolve: {
|
||||||
|
|
@ -35,7 +35,7 @@ module.exports = env => ({
|
||||||
// TODO: CSS follow imports and minify + sourcemap on production
|
// TODO: CSS follow imports and minify + sourcemap on production
|
||||||
{ test: /\.css$/, use: [ 'style-loader', 'css-loader' ] },
|
{ test: /\.css$/, use: [ 'style-loader', 'css-loader' ] },
|
||||||
{ test: /\.(woff2?|eot|ttf|svg)$/, loader: "file-loader" },
|
{ test: /\.(woff2?|eot|ttf|svg)$/, loader: "file-loader" },
|
||||||
{ test: /\.js(x)?$/, exclude: /node_modules/, loader: "babel-loader?cacheDirectory=true" }
|
{ test: /\.js(x)?$/, loader: "babel-loader?cacheDirectory=true" }
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
plugins: [
|
plugins: [
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue