fix: Prevent storybook from making websocket connections (#2896)
* feat: mock window.WebSocket to prevent WS calls from Main layout story * Prettified Code! --------- Co-authored-by: Pranav2612000 <Pranav2612000@users.noreply.github.com>
This commit is contained in:
@@ -36,6 +36,10 @@ export default {
|
|||||||
},
|
},
|
||||||
} satisfies ComponentMeta<typeof Main>;
|
} satisfies ComponentMeta<typeof Main>;
|
||||||
|
|
||||||
|
// mock the Websocket to prevent ani webhook calls from being made in storybook
|
||||||
|
// @ts-ignore
|
||||||
|
window.WebSocket = () => {};
|
||||||
|
|
||||||
type StateInitializer = (mutableState: MutableSnapshot) => void;
|
type StateInitializer = (mutableState: MutableSnapshot) => void;
|
||||||
|
|
||||||
const composeStateInitializers =
|
const composeStateInitializers =
|
||||||
|
|||||||
Reference in New Issue
Block a user