Skip to content
Kitbay

studio-queries

Apache-2.0Updated on Nov 11, 2026114,826GitHub stars

A maintainer skill in the Supabase monorepo with the conventions for fetching data in Supabase Studio, the dashboard app, using TanStack React Query.

What the skill teaches

A maintainer skill in the Supabase monorepo with the conventions for fetching data in Supabase Studio, the dashboard app, using TanStack React Query. Query keys live in a keys file for each domain rather than inside components, and query options are built from private fetch functions that check their inputs and handle errors. Queries run only when their required values exist, permission-gated queries use a dedicated helper that a lint rule protects, and code outside rendering fetches through the query client. Mutation hooks invalidate the related list and detail keys and show an error toast by default, and components render loading, error and success states in that order. The table editor and edge functions code serve as examples.

Capabilities

  • Write React Query hooks for Studio
  • Define query keys per domain
  • Invalidate related queries after mutations
  • Review data-fetching code against the conventions