Paciolan / remote-module-loader

Loads a CommonJS module from a remote URL for the Browser or Node.js.
MIT License
85 stars 21 forks source link

chore: add webpack5 polyfill #30

Open smeng9 opened 1 year ago

smeng9 commented 1 year ago

Currently when we use the @paciolan/remote-component in create-react-app 5.0.1 (webpack 5), it will throw errors "webpack < 5 used to include polyfills for node.js core modules..." as webpack 5 no longer polyfills http and https node module.

We need to include polyfill dependencies by ourselves and use a browser field.

smeng9 commented 1 year ago

Closes https://github.com/Paciolan/remote-module-loader/issues/27

smeng9 commented 1 year ago

Linked issue: https://github.com/Paciolan/remote-component/issues/52