-
Notifications
You must be signed in to change notification settings - Fork 9.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[tracking] replace brfs #13231
Labels
Comments
This was referenced Oct 20, 2021
This was referenced Oct 21, 2021
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
We've used
brfs
for a very long time (introduced in #225), and have gone through a number of cycles of updating it, waiting for it to be updated, and rolling our own slightly tweaked versions. However we're moving on from browserify due to the move to ESM and the desire to get away with the difficulties of such an old toolchain (e.g. #12134) and it's similarly time to make a clean break frombrfs
.There aren't a lot of drop-in replacements out there and it's not a very complicated transform, so we're just going to write out own.
Goals:
fs.readFileSync
andfs.readdirSync
calls with statically evaluatable argumentsLH_ROOT
support)fs
method call being replaced. Since the types of syntax used to make the arguments to thefs
calls largely hasn't changed in LH since maybe rest parameters were introduced, this should eliminate a large number of the upgrade pains we've had where syntax anywhere in the file has broken browserify and/or brfsNon-goals
fs.readFileSync
call is actually a method on the Nodefs
API and not some local variablefs = {readFileSync: () => true}
or whatever.LH_ROOT
The text was updated successfully, but these errors were encountered: