diff --git a/reflex/.templates/web/utils/state.js b/reflex/.templates/web/utils/state.js index 622f171ad..e135c7c0b 100644 --- a/reflex/.templates/web/utils/state.js +++ b/reflex/.templates/web/utils/state.js @@ -799,7 +799,7 @@ export const useEventLoop = ( connect( socket, dispatch, - ["websocket", "polling"], + ["websocket"], setConnectErrors, client_storage ); diff --git a/reflex/app.py b/reflex/app.py index 3f981a6c3..cf4eefa19 100644 --- a/reflex/app.py +++ b/reflex/app.py @@ -363,6 +363,7 @@ class App(MiddlewareMixin, LifespanMixin): max_http_buffer_size=constants.POLLING_MAX_HTTP_BUFFER_SIZE, ping_interval=constants.Ping.INTERVAL, ping_timeout=constants.Ping.TIMEOUT, + transports=["websocket"], ) elif getattr(self.sio, "async_mode", "") != "asgi": raise RuntimeError(