Closed whaaaley closed 4 years ago
const browserify = require('browserify') const watchify = require('watchify') const hmr = require('browserify-hmr') const fs = require('fs') const entries = [ 'src/dash.js', 'src/home.js' ] const outputs = [ 'dist/dash.js', 'dist/home.js' ] var b = browserify({ entries: entries, cache: {}, packageCache: {} }) .transform('vueify') .plugin(watchify) .plugin(hmr) .plugin('factor-bundle', { outputs: outputs }) function bundle() { b.bundle().pipe(fs.createWriteStream('dist/common.js')) } b.on('update', bundle) bundle()
There's a high chance I'm doing something wrong here, but i've spent a whole day trying different ways but the output is always _hmr_manager.js. I've also tried doing CLI commands and no luck there either.
_hmr_manager.js
Sorry, I don't think it's compatible with factor-bundle right now. I'll look into this sometime.
There's a high chance I'm doing something wrong here, but i've spent a whole day trying different ways but the output is always
_hmr_manager.js
. I've also tried doing CLI commands and no luck there either.