MCPcopy Index your code
hub / github.com/TanStack/devtools / mountDevtools

Function mountDevtools

packages/devtools/src/mount-impl.tsx:27–53  ·  view source on GitHub ↗
(options: MountOptions)

Source from the content-addressed store, hash-verified

25}
26
27export function mountDevtools(options: MountOptions): MountResult {
28 const { el, plugins, config, eventBusConfig, onSetPlugins } = options
29
30 const eventBus = new ClientEventBus(eventBusConfig)
31 eventBus.start()
32
33 const Devtools = lazy(() => import('./devtools'))
34
35 const dispose = render(
36 () => (
37 <DevtoolsProvider
38 plugins={plugins}
39 config={config}
40 onSetPlugins={onSetPlugins}
41 >
42 <PiPProvider>
43 <Portal mount={el}>
44 <Devtools />
45 </Portal>
46 </PiPProvider>
47 </DevtoolsProvider>
48 ),
49 el,
50 )
51
52 return { dispose, eventBus }
53}

Callers 1

mountMethod · 0.85

Calls 1

startMethod · 0.95

Tested by

no test coverage detected