Skip to content

Commit

Permalink
Added proper, working babel.config.js to project
Browse files Browse the repository at this point in the history
Inadvertently a non-functioning, test version of the babel config file was committed with the last PR.  Commiting the real version with this.
  • Loading branch information
scottrumsby committed Apr 22, 2019
1 parent 0ac61ee commit cbf460b
Show file tree
Hide file tree
Showing 3 changed files with 63 additions and 52 deletions.
43 changes: 22 additions & 21 deletions frontend/babel.config.js
Original file line number Diff line number Diff line change
@@ -1,35 +1,36 @@
module.exports = function(api) {
api.cache.using( () => process.env.NODE_ENV !== 'test')
const isTest = api.env('test')
if (isTest) {
if (api.env('test')) {
return {
presets: [
[
'@babel/preset-env',
{
useBuiltIns: "usage",
corejs: "3",
targets: {
ie: "11"
}
},
browsers: [
'last 10 Chrome versions'
]
},
useBuiltIns: 'usage',
corejs: 3,
}
]
],
]
}
}
return {
presets: [
'@vue/app',
[
'@babel/preset-env',
{
useBuiltIns: "usage",
corejs: "3",
targets: {
ie: "11"
}
},
]
]
'@babel/preset-env',
{
modules: false,
targets: {
browsers: ['> 1%','last 2 versions', 'not ie <= 10'],
},
useBuiltIns: 'usage',
corejs: 3,
}
],
],

}
}
}
69 changes: 40 additions & 29 deletions frontend/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,7 @@
"lint": "eslint --ext .js,.vue src"
},
"dependencies": {
"@babel/polyfill": "^7.0.0",
"@babel/runtime-corejs2": "^7.4.3",
"@babel/runtime-corejs3": "^7.4.3",
"@fortawesome/fontawesome-free": "^5.7.0",
"@fortawesome/fontawesome-svg-core": "^1.2.8",
"@fortawesome/free-regular-svg-icons": "^5.7.1",
Expand Down

0 comments on commit cbf460b

Please sign in to comment.