从 watchify 的文档中,我了解到:
When creating the browserify instance b you MUST set these properties in the constructor:
var b = browserify({ cache: {}, packageCache: {}, fullPaths: true })
这 3 个参数 cache: {}, packageCache: {}, fullPaths: true
是为了 watchify,但为什么我们要将它们传递给 browserify
而不是传递给 watchify
呢?