Как отображать шаблон Vue в JavaScript с Gulp
gulp.task('bundle-for-dev', function () {
return browserify({entries: ['./src/js/entry.js']}) // path to your entry file here
.transform(vueify)
.plugin('vueify/plugins/extract-css', { out: './tmp/css/bundle.css' }) // path to where you want your css
.transform(babelify, {"presets": ["es2015"]})
.external('vue') // remove vue from the bundle, if you omit this line whole vue will be bundled with your code
.bundle()
.pipe(source('bundle.js'))
.pipe(gulp.dest('./tmp/js'));
})
Stone Sheep