Skip to content
TypeWire

@tahanabavi/type-devtools

documents v1.0.1

React inspector panel for the TypeWire ecosystem — one timeline for HTTP and WS, a live query cache, a runtime override editor, and theme/sound settings.

Setup

Wire your clients into a bridge, then render the panel:

tsx
import {
InspectorBridge,
connectTypeFetch,
connectTypeSocket,
connectQueryClient,
TypeDevtools,
} from "@tahanabavi/type-devtools";

const bridge = new InspectorBridge();
connectTypeFetch(apiClient, bridge); // HTTP
connectTypeSocket(socketClient, bridge); // WebSocket

// Optional: attach a query client to unlock the Cache tab.
const queries = connectQueryClient(queryClient);

function Root() {
return (
<>
<App />
<TypeDevtools bridge={bridge} queries={queries} />
</>
);
}

queries is optional — omit it and the Cache tab simply doesn't appear.

Props

PropTypeDefault
bridgeInspectorBridgeThe transport timeline (required).
queriesQueryInspectorAttach a query cache to show the Cache tab.
defaultOpenbooleanfalseRender expanded on first mount.
titlestring"TypeWire devtools"Header label.