Skip to content
Source
Sign inSign up
TanStack/devtools
Open History to see the last commit

tanstackdevtoolsinit.md

73 lines1.7 KB

1---
2id: TanStackDevtoolsInit
3title: TanStackDevtoolsInit
4---
5​
6<!-- DO NOT EDIT: this page is autogenerated from the type comments -->
7​
8# Interface: TanStackDevtoolsInit
9​
10Defined in: [devtools/src/core.tsx:13](https://github.com/TanStack/devtools/blob/main/packages/devtools/src/core.tsx#L13)
11​
12## Properties
13​
14### config?
15​
16```ts
17optional config: Partial<{
18 customTrigger: (el, props) => void;
19 defaultOpen: boolean;
20 hideUntilHover: boolean;
21 openHotkey: KeyboardKey[];
22 panelLocation: "top" | "bottom";
23 position: TriggerPosition;
24 requireUrlFlag: boolean;
25 theme: "light" | "dark";
26 triggerHidden: boolean;
27 urlFlag: string;
28}>;
29```
30​
31Defined in: [devtools/src/core.tsx:19](https://github.com/TanStack/devtools/blob/main/packages/devtools/src/core.tsx#L19)
32​
33Configuration for the devtools shell. These configuration options are used to set the
34initial state of the devtools when it is started for the first time. Afterwards,
35the settings are persisted in local storage and changed through the settings panel.
36​
37***
38​
39### eventBusConfig?
40​
41```ts
42optional eventBusConfig: ClientEventBusConfig;
43```
44​
45Defined in: [devtools/src/core.tsx:40](https://github.com/TanStack/devtools/blob/main/packages/devtools/src/core.tsx#L40)
46​
47***
48​
49### plugins?
50​
51```ts
52optional plugins: TanStackDevtoolsPlugin[];
53```
54​
55Defined in: [devtools/src/core.tsx:39](https://github.com/TanStack/devtools/blob/main/packages/devtools/src/core.tsx#L39)
56​
57Array of plugins to be used in the devtools.
58Each plugin has a `render` function that gives you the dom node to mount into
59​
60Example:
61```ts
62 const devtools = new TanStackDevtoolsCore({
63 plugins: [
64 {
65 id: "your-plugin-id",
66 name: "Your Plugin",
67 render: (el) => {
68 // Your render logic here
69 },
70 },
71 ],
72 })
73```