-
Notifications
You must be signed in to change notification settings - Fork 13
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
process
polyfill is missing methods
#33
Comments
There’s a mock implementation for browser environment, but I don’t know if that’s enough. As for making changes and how to proceed, do you know the steps which would take to make this possible for all users of all respective modules? This module is used as dependancy in a lot of Vite plugins, and Webpack implementation is here but not as simple as dedicated plugin. |
Thank you very much for your responses. There doesn't seem to be anything to do immediately, but it really would be nice to have a some kind of jailbreak for webpack+electron-forge where It's all kinds of hassles to jump through the existing IPC API that electron (recent versions, say 30.x onward) supplies to get communication to work between the main thread and the renderer. It's actually worst than that because electronjs.org docs are apparently out of date (in the sense that their published examples for IPC don't work out of the box!) , not to mention, it slows things down by 2x or more. The fact that zeromq/zeromq.js#676 can't be loaded up directly on the renderer side is just awful, due to missing I'm willing to do the heavy lifting to get a (new name alert) Here is my first stab at a brainstorm for this (probably wrong, because I am a webpack n00b)
Any tips or ideas you guys can throw my way would be great. |
@niksy I'm thinking that so long as we continue isolating each polyfill in separate files/exports, I can just import and re-export them, passing them to Webpack.
This is interesting, I missed it the first time I looked. I think I would like the platform/architecture info to be more specific, enough to be compliant with Node.js APIs. |
@Richienb also, have a look at proxy implemention for The idea was to augment external modules with additional exports since those modules haven’t catch up with recent Node internals changes (see also defunctzombie/node-url#59 (comment)) Maybe this can also be done for As for org changes and future maintenance, I’m open to all suggestions. I’ve created this module soon as Webpack stopped active maintenance of their implementation and I’ve found out this is still really useful to a lot of developers. |
I’ve created PR where we can see if this is what’s needed for this issue to be resolved from this side. |
Release as part of https://github.com/niksy/node-stdlib-browser/releases/tag/v1.3.0! @devzzzero if you’re not using latest version of https://github.com/Richienb/node-polyfill-webpack-plugin, install it and you should get changes. If you already have it installed, reinstall it so minor version bump gets picked up. |
Thank you @niksy ! |
I maintain a Webpack plugin
node-polyfill-webpack-plugin
that provides similar functionality to this module, but in a simpler, Webpack-only, interface.Richienb/node-polyfill-webpack-plugin#58 notes that the
process
polyfill is missingprocess.platform
andprocess.arch
. This issue, among others also appears here but is unreported.Instead of making the change only within my own plugin, maybe we could consolidate together into an org, such that I make polyfill improvements in this repo and then import the module into mine?
The text was updated successfully, but these errors were encountered: