When building less file A that imports another less file B and B contains declaration that needs to be resolved e.g. url() and this path is relative to B esbuild does not find this file correctly.
It tries to resolve file relatively to main less file instead of the file that references image
say /home/esbuild is absolute path to project root
Versions
esbuild: 0.14.42
esbuild-plugin-less: 1.1.7
Platform: Ubuntu 21.10
Note
Maybe this is expected behaviour and I do not understand something but somehow webpack makes this work, and now I try to migrate and can't make it work in esbuild.
What happens
When building less file A that imports another less file B and B contains declaration that needs to be resolved e.g. url() and this path is relative to B esbuild does not find this file correctly.
It tries to resolve file relatively to main less file instead of the file that references image
Steps to Reproduce the Problem
Output
say
/home/esbuild
is absolute path to project rootVersions
esbuild
: 0.14.42esbuild-plugin-less
: 1.1.7Note
Maybe this is expected behaviour and I do not understand something but somehow webpack makes this work, and now I try to migrate and can't make it work in esbuild.