Vite fails to resolve assets from packages when specified as new URL('asset-file-name', import.meta.url)
in dev mode
#19310
Labels
new URL('asset-file-name', import.meta.url)
in dev mode
#19310
Describe the bug
Vite will fail to resolve assets from packages in dev mode, when it's specified as the following format:
new URL('asset-file-name', import.meta.url)
Reproduction
https://github.com/fs-eire/vite-bug-repro-asset-import-meta-url
Steps to reproduce
Please follow the README in the reproduction steps in https://github.com/fs-eire/vite-bug-repro-asset-import-meta-url
System Info
Used Package Manager
npm
Logs
Please refer to the reproduction repo for more details.
The bug only exists in dev mode. In production mode, it works fine.
Validations
The text was updated successfully, but these errors were encountered: