-
Notifications
You must be signed in to change notification settings - Fork 26
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
Allow externalized Wasm build #96
Comments
Also see the explanation in #94 (comment).
There was never one.
Sounds good to me! If this is the case: we'd like to keep a separate script in this repo, to generate a CJS shim for Node to load the builtin from an external NPM module in downstream distro builds. Also, can I implement this by further stripping on top of #91? To be honest, I'm not a huge fan of
An addition optional
Yes. That would work! |
We landed and reverted #91 which gave the ability to point to an externalized Wasm file for the lexer build.
As far as I'm aware the primary requirement here was not to use base64 encoding, but to instead load the Wasm from a separate file, that could be vetted at distribution time.
Therefore the suggestion is to have two builds of cjs-module-lexer - one like the existing one that inlines the base64 and one new one that automatically loads the lexer wasm from a separate wasm file.
In our build process we then generate these two new builds allowing consumers to select which one they want to use.
There is therefore:
I am also still unclear on why a new exports entry point was needed for this alternative build as well. There is already CJS entry point generation in the
npm run build
script, which just needs to be extended to the new entry point being generated as well.//cc @mochaaP
The text was updated successfully, but these errors were encountered: