Open ii02735 opened 2 months ago
Passthrough is imported from stream
. So have you tried importing stream
instead of _stream_passthrough
?
Also try setting protocolImports: true
, since it is importing Passthrough from node:
protocol import.
I encountered the same issue and this fixed it for me.
Summary
In a project, I use the following dependency : https://www.npmjs.com/package/minify-xml
Because it is a dependency written for a pure NodeJS project, I had to use polyfills like this :
What I expect
Everything should work in dev mode, or when I build the project.
What I got
I have the following error :
My setup
You can find a minimal reproductible example there : https://github.com/ii02735/vite-minify-xml-bug-build