package: use babel env with exact targets (chrome 50 and ios 9.3)
This commit is contained in:
parent
ec21a4f249
commit
55ea829109
3 changed files with 13 additions and 2 deletions
11
.babelrc
Normal file
11
.babelrc
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
{
|
||||
"presets": [
|
||||
["env", {
|
||||
"targets": {
|
||||
"ios": "9.3",
|
||||
"chrome": "50"
|
||||
}
|
||||
}]
|
||||
],
|
||||
"plugins": ["transform-object-rest-spread"]
|
||||
}
|
||||
|
|
@ -21,7 +21,7 @@
|
|||
"dependencies": {
|
||||
"autolayout": "0.7.0",
|
||||
"babel-plugin-transform-object-rest-spread": "6.26.0",
|
||||
"babel-preset-es2015": "6.24.1",
|
||||
"babel-preset-env": "*",
|
||||
"babelify": "7.3.0",
|
||||
"browserify": "14.4.0",
|
||||
"cardinal-spline-js": "^2.3.6",
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ b = browserify(path.resolve(__dirname + '/../src/browser/js/browser.js'), {debug
|
|||
|
||||
b.plugin(licensify)
|
||||
|
||||
b = b.transform(babelify, {presets: ["es2015"], plugins: ["transform-object-rest-spread"]})
|
||||
b = b.transform(babelify, {presets: ["env"]})
|
||||
|
||||
if (prod) b = b.transform('uglifyify', {global: true})
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue