@orderly.network/hooks
import { useWS } from "@orderly.network/hooks"; //... export const Example = () => { const ws = useWS(); useEffect(() => { const unsubscribe = ws.subscribe( { id: "wallet", event: "subscribe", topic: "wallet", ts: Date.now() }, { onMessage: (data: any) => { // } } ); return () => { unsubscribe(); }; }, [ws]); };