Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

UnhandledSchemeError: Reading from "node:zlib" is not handled by plugins (Unhandled scheme)

Tags:

webpack

Anyone can help resolve this error? I have tried resolving using polyfills and every other solution i could find online and think by myself but i still keep getting the issues

like image 620
wakil Avatar asked May 28 '26 21:05

wakil


1 Answers

Option A

I also encountered this issue when using node-fetch: ^3.0.0 but downgrading to node-fetch: ^2.0.0 resolved it for me.


Option B

You need to declare these as externals. https://webpack.js.org/configuration/externals/

Webpack 4

  target: node

Webpack 5

  externalsPresets: { node: true },

I also use webpack-node-externals but this might not apply in your case.

Related issue: https://github.com/webpack/webpack/issues/13290

like image 91
Kevin Farrugia Avatar answered May 30 '26 13:05

Kevin Farrugia



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!