elado / next-with-less

Next.js + Less CSS Support
MIT License
143 stars 24 forks source link

Failed to resolve node_module paths in url(...) statements with next@12 #25

Open duyphaphach opened 2 years ago

duyphaphach commented 2 years ago

Hi 🙂, I want to report an issue when upgrading to next@12

Versions

Issue

node_modules paths in url(...) like ~bootstrap/fonts/glyphicons-halflings-regular.eot is resolved into relative path: ./bootstrap/fonts/glyphicons-halflings-regular.eot

Happened when bumping to next@12 and next-with-less@2.0.5

It worked fine in next@11 and next-with-less@1.0.1

Reproduction

Working demo with next@11 Breaking demo with next@12

MartinKei commented 1 year ago

@duyphaphach I'm running into a similar issue with a referenced image from leaflet in my code.

Did you ever resolve that?