-
-
Save Fl0pZz/fcfc87420ceceee7dba01c6ece1f493a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Show hidden characters
{ | |
"presets": [ | |
["env", { | |
"modules": false, | |
"targets": { | |
"browsers": ["> 1%", "last 2 versions", "not ie <= 8"] | |
} | |
}], | |
"stage-2" | |
], | |
"plugins": ["transform-runtime"], | |
"env": { | |
"test": { | |
"presets": ["env", "stage-2"], | |
"plugins": ["istanbul"] | |
} | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ERROR in static/js/5.93ab66d4a749cd072641.js from UglifyJs | |
Unexpected token: name (resolvePromise) [./node_modules/vue-charts/src/utils/makeDeferred.js:6,0][static/js/5.93ab66d4a749cd072641.js:20667,6] | |
ERROR in static/js/6.607ca16377a1e18dc831.js from UglifyJs | |
Unexpected token: name (resolvePromise) [./node_modules/vue-charts/src/utils/makeDeferred.js:6,0][static/js/6.607ca16377a1e18dc831.js:20638,6] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
This lets us resolve the promise outside the | |
promise function itself. | |
*/ | |
export function makeDeferred () { | |
let resolvePromise = null | |
let rejectPromise = null | |
let promise = new Promise((resolve, reject) => { | |
resolvePromise = resolve | |
rejectPromise = reject | |
}) | |
return { | |
promise: promise, | |
resolve: resolvePromise, | |
reject: rejectPromise | |
} | |
} | |
export default makeDeferred |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ... | |
new webpack.optimize.UglifyJsPlugin({ | |
compress: { | |
warnings: false | |
}, | |
sourceMap: true, | |
uglifyOptions: { | |
ie8: false, | |
ecma: 7 | |
} | |
}) | |
// ... |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment