memfs
memfs copied to clipboard
Remove built-in dependencies
Review and try to remove built-in Node.js module dependencies, so they are not bundled when building for web.
- [ ]
path - [ ]
process - [ ]
stream— is there a way to make thestreammodule optional?- [ ] Or maybe explicitly install
readable-streamas required dependency.
- [ ] Or maybe explicitly install
- [ ]
buffer— create a thin wrapper aroundUint8Array, whenBufferglobal is missing. - [ ]
util- [ ]
util.inherits()
- [ ]
- [ ] Error messages
- [ ]
internal/errors.ts— Node-like errors vendored module - [ ]
assert- [ ]
assert.strictEqual() - [ ]
assert()
- [ ]
- [ ]
url- [ ]
url.URL
- [ ]
- [ ]
util- [ ]
util.format() - [ ]
util.inspect()
- [ ]
- [ ]
Hey @streamich shouldn't this list include stream as well since memfs uses Readable, Writable?
We will always need some stream implementation, due to fs.createReadStream() and fs.createWriteStream().
Maybe we could explicitly install readable-stream dependency, instead of relying on Node's built-in stream.