diff --git a/.babelrc b/.babelrc new file mode 100644 index 0000000..f97d0ef --- /dev/null +++ b/.babelrc @@ -0,0 +1,27 @@ +// Parceljs cann't compile babel.config.js +{ + "presets": [ + [ + "@babel/preset-env", + { + "modules": false + } + ] + ], + "plugins": ["transform-vue-jsx", "@babel/plugin-transform-object-assign"], + "env": { + "test": { + "presets": [ + [ + "@babel/preset-env", + { + "targets": { + "node": "current" + } + } + ] + ], + "plugins": ["transform-vue-jsx"] + } + } +} diff --git a/babel.config.js b/babel.config.js index 3f68a9f..9a3f02c 100644 --- a/babel.config.js +++ b/babel.config.js @@ -1,3 +1,4 @@ +// need to compile node_modules (eg: vue-runtime-helps) module.exports = api => { api.cache(false); return {