Open cdll opened 5 years ago
i've got problem with bundling jsx render function in Vue2 with jspm build, such as:
jspm build
//main.js import('vue2') .then(Vue=>{ const vm= new Vue({ data: {} ,el: '#AppMain' ,methods: { pageScrolling(){ store.commit('pageScrolling', event.target.scrollTop) } } ,render(){ return ( <div id='AppMain' onScroll={this.pageScrolling}> <router-view></router-view> <mu-snackbar></mu-snackbar> </div> ) } }) })
even after i 'd tried
//jspm.config.js System.config({ //... meta: { "*.js": { "babelOptions": { "es2015": true ,preset: ['vue'] ,plugins: [ "babel-plugin-transform-vue-jsx" ] } } }, //... })
but i used to use babel-plugin-transform-vue-jsx in my gulp and gulp-babel task to successly bundle my main.js. could anybody give me some help and thanks a lot~
babel-plugin-transform-vue-jsx
main.js
the error that i got
i've got problem with bundling jsx render function in Vue2 with
jspm build
, such as:even after i 'd tried
but i used to use
babel-plugin-transform-vue-jsx
in my gulp and gulp-babel task to successly bundle mymain.js
. could anybody give me some help and thanks a lot~