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
When using dx serve with a custom Axum websocket endpoint (using WebSocketUpgrade), websocket connections between the browser and the server fail, even though the same code works when using dx bundle.
Also see #2155 which was previously closed, but this is still an issue for browser-to-server connections.
Steps To Reproduce
Steps to reproduce the behavior:
Cargo.toml
[dependencies]
dioxus = { version = "0.6.3", features = ["fullstack"] }
dioxus-cli-config = "0.6.3"futures = "0.3.31"tokio = { version = "1.43.0", optional = true }
axum = { version = "0.7.9", optional = true }
gloo = { version = "0.11.0", optional = true, features = ["net"] }
[features]
default = []
web = ["dioxus/web", "dep:gloo"]
server = ["dioxus/server", "dep:tokio", "dep:axum"]
Problem
When using
dx serve
with a custom Axum websocket endpoint (usingWebSocketUpgrade
), websocket connections between the browser and the server fail, even though the same code works when usingdx bundle
.Also see #2155 which was previously closed, but this is still an issue for browser-to-server connections.
Steps To Reproduce
Steps to reproduce the behavior:
Cargo.toml
main.rs
dx bundle --platform web && target/dx/$PROJECT_NAME/release/web/server
dx serve
Expected behavior
The websocket message is successfully received by the server in both cases.
Actual output
The connection fails to be established when using
dx serve
:Environment:
Questionnaire
The text was updated successfully, but these errors were encountered: