You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Man... this hole just keeps getting bigger and bigger doesn't it :(
Here I was trying to make a cool extension to output files in a library so they can be subpath imported as well as cross compiled for CJS and ESM (for example it's used in https://github.com/sapphiredev/utilities/tree/main/packages/utilities) but then this plugin became more and more popular and now there's lot of edge cases to account for. Not that I mind the rising popularity, on the contrary, but it's still a bother for all users.
As for a way to fix it, maybe instead of just scanning package.json the code should recursively scan all subdependencies?
Is there an existing issue for this?
Description of the bug
The dependency matcher works after bundling is done, this fails because subdependencies aren't matched.
https://github.com/KaisSalha/esbuild-plugin-file-path-extensions-bug/blob/76f3f4a4fdc5fc6fc0c0def14b738b1335d538f6/dist/index.js#L15265
I can look into this some time later, but I'll busy for a while.
Steps To Reproduce
https://github.com/KaisSalha/esbuild-plugin-file-path-extensions-bug/tree/with-fix
Expected behavior
Have it work without bundling?
Have it run before bundling?
Rethink dependency matcher?
Screenshots
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: