fix: remove node.js dependency in browser#1081
fix: remove node.js dependency in browser#1081sserrata merged 1 commit intoPaloAltoNetworks:mainfrom
Conversation
|
Visit the preview URL for this PR (updated for commit 2e73145): https://docusaurus-openapi-36b86--pr1081-lq3u8386.web.app (expires Thu, 13 Mar 2025 18:43:09 GMT) 🔥 via Firebase Hosting GitHub Action 🌎 Sign: bf293780ee827f578864d92193b8c2866acd459f |
|
Hi @himself65, thanks for the PR...there seems to be some issues with CSR: On initial load and route change I'm not getting past the loading skeletons:
|
thanks for checking. I see there is a |
392b618 to
2e73145
Compare
blindaa121
left a comment
There was a problem hiding this comment.
Thanks for the PR @himself65! For context, I believe the polyfill package was initially added to provide support for our postman library (see #422). Since this package has since been removed from the project, I think your solution should be good to go.
@sserrata Thoughts?
|
To clarify, Our theme still relies on both the @himself65 thanks for the work on replacing my use of |


Description
Node.js core modules are imported in client(browser) side. And the previsous code use node polyfill, however this would brings more issue:
node:buffer,node:zlib... wherenode:as prefix would still break the webpack bundler becausenode-polyfill-webpack-plugindidn't handle it correctlyBuffercould leads unexpected behaviorThis PR remove node.js dependency, instead now uses pika and web api directly to reduce the bundle hack, bundle size and more explicit imports
Motivation and Context
For more context, docusaurus will raise error if use nolyfill
How Has This Been Tested?
Try this in demo and everything works
Screenshots (if appropriate)
Types of changes
Checklist