Set initialDataReceived on first websocket payload
This commit is contained in:
parent
26442beca1
commit
aa7b7b0922
1 changed files with 2 additions and 2 deletions
|
|
@ -326,8 +326,8 @@ export function createWebSocketStore(url: string) {
|
||||||
) {
|
) {
|
||||||
// Update state properties individually to ensure reactivity
|
// Update state properties individually to ensure reactivity
|
||||||
if (message.data) {
|
if (message.data) {
|
||||||
// Mark that we've received initial data
|
// Mark that we've received usable data (initial payload or raw update)
|
||||||
if (message.type === WEBSOCKET.MESSAGE_TYPES.INITIAL_STATE) {
|
if (!initialDataReceived()) {
|
||||||
setInitialDataReceived(true);
|
setInitialDataReceived(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue