Skip to content
Source
Sign inSign up
TanStack/query

feat(devtools): Add move devtools select menu #4100

Mergedsalamaashoush(GitHub profile, opens in a new tab)merged 3 commits intomain fromrefs/pull/4100/headmerged by TkDodo View on GitHub

Showing 4 changed files with 130 additions and 22 deletions (loading 2).

x
0 of 4 viewed, 4 left
31 additions and 22 deletionsdocs/devtools.mdModified
View file
@@ -61,6 +61,9 @@
- `position?: "top-left" | "top-right" | "bottom-left" | "bottom-right"`
- Defaults to `bottom-left`
- The position of the React Query logo to open and close the devtools panel
+- `panelPosition?: "top" | "bottom" | "left" | "right"`
+ - Defaults to `bottom`
+ - The position of the React Query devtools panel
- `context?: React.Context<QueryClient | undefined>`
- Use this to use a custom React Query context. Otherwise, `defaultContext` will be used.
​
@@ -89,6 +92,10 @@
- The standard React style object used to style a component with inline styles
- `className: string`
- The standard React className property used to style a component with classes
+- `showCloseButton?: boolean`
+ - Show a close button inside the devtools panel
+- `closeButtonProps: PropsObject`
+ - Use this to add props to the close button. For example, you can add `className`, `style` (merge and override default style), `onClick` (extend default handler), etc.
​
## Devtools in production
​
@@ -103,30 +110,32 @@
const queryClient = new QueryClient()