module-deps
module-deps copied to clipboard
Readable streams can be passed to opts.fileCache
Allows stream.Readable instances in fileCache. Duck-typing the stream so other allowed types (String/Buffer) will not be affected.
Seemed like there is no provided way to persist the cache. I'm using a Proxy's getOwnPropertyDescriptor trap (triggered by xhas) to dynamically populate the cache with asynchronous fs.readFile calls.
Would otherwise suggest having an asynchronous fileRead API with a cache lookup callback in the options.
I think this need is addressed by the persistentCache option that was added in https://github.com/browserify/module-deps/pull/124?