Cache busting query string breaks URLs with an existing query string #3307
Labels
bug
Something isn't working
desktop
Suggestions related to the desktop renderer
hot-reload
Related to the hot reload crate
web
relating to the web renderer for dioxus
Problem
To enable Dioxus' hot reload, a random float is added as a query string to URLs for assets. If the URL already contains a query string, e.g.
https://example.com?foo=bar
, appending?0.123435212
creates an invalid URL. This can interfere with requesting remote resources.Steps To Reproduce
Steps to reproduce the behavior:
dx new web
document::Stylesheet { href: asset!("https://example.com?foo=bar") }
Expected behavior
To enable cache busting, I would expect a URL to get a new query string key/value pair when the URL already contains a query string, e.g.
https://example.com?foo=bar&cache-bust=0.323432432
. If the URL does not contain a query string, I would expect the current behavior, e.g.https://example.com?cache-bust=0.352432432
.Environment:
0.6.0
nightly
fullstack
The text was updated successfully, but these errors were encountered: