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
Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
Make sure this is a Vite issue and not a framework-specific issue. For example, if it's a Vue SFC related bug, it should likely be reported to vuejs/core instead.
Hi, this is still broken for URLs with commas in path, eg. https://res.cloudinary.com/hackercamp/image/upload/dpr_auto,f_auto,fl_progressive,q_auto,w_100/v1/www.hackercamp.cz/faq-ubytko-3?_a=BAMABmTE0
Describe the bug
Vite appears to add spaces around commas when a comma is present in a
srcset
property. This only occurs in HTML files.If my index.html file contains
Vite outputs
Take note of the space added to the image url around the comma in the query parameter.
?im=Resize , width=800
The browser reads
width=800
as the entire image url and attempts to request/width=800
which is nonexistent.Reproduction
Code Sandbox
Steps to reproduce
reproduceable with
vite
vite preview
andvite build
System Info
Used Package Manager
npm
Logs
Browser Logs
```shell Uncaught TypeError: Cannot set properties of null (setting 'innerHTML') at main.ts:6:49 ```Vite Logs
```shell vite:resolve 0.64ms /width=800 -> null +5s vite:html-fallback Rewriting GET /width=800 to /index.html +228ms ```Validations
The text was updated successfully, but these errors were encountered: