What version of parcel are you using?
Looking at the error it might be related to htmlnano and svg minification. Try creating a .htmlnanorc
file and add { "minifySvg": false }
to see if it works then. Or try running the build with the flag --no-optimize
to disable all minification. Delete the parcel cache as well between builds with a new config.
https://v2.parceljs.org/languages/html/
It does look like there have been updates to the dependencies which might fix it as well. You would need to manually update the dependencies. I’m not sure how easy it is considering how they are integrated into parcel.
Example:
node_modules\htmlnano
node_modules\@parcel\optimizer-htmlnano
It would be helpful if you created a repo with your project so it’s easier to test.