Shopify + Sanity: Read about the investment and partnership –>

Documents Pane

By Simeon Griggs & Victoria Bergquist

Display the results of any GROQ Query inside a View Pane


Displays the results of a GROQ query in a View Pane. With the ability to use field values in the current document as query parameters.

Incoming References


sanity install documents-pane

This plugin is designed to be used as a Component inside of a View.

The example below illustrates using the current Document being used to query for all Documents that reference it.

// ./src/deskStructure.js
import DocumentsPane from 'sanity-plugin-documents-pane'

// ...all other list items

    query: `*[!(_id in path("drafts.**")) && references($id)]`,
    params: {id: `_id`},
    useDraft: false,
    debug: true,
  .title('Incoming References')

The .options() configuration works as follows:

  • query (string, required)
  • params (object, optional) A dot-notated string from the document object to a field, to use as variables in the query.
  • useDraft (bool, optional, default: false) When populating the params values, it will use the published version of the document by default.
  • debug (bool, optional, default: false) In case of an error or the query returning no documents, setting to true will display the query and params that were used.


This plugin is based on Incoming References originally written by Victoria Bergquist.


MIT © Simeon Griggs See LICENSE

Install command

sanity install documents-pane


Categorized in

Other plugins by authors

Orderable Document List
- has 24 likes

Official(made by Sanity team)

Drag-and-drop Document Ordering without leaving the Editing surface

Simeon Griggs
Go to Orderable Document List

Content Calendar
- has 14 likes

Official(made by Sanity team)

Schedule and view your editorial calendar, right where you store your content. Prioritize and get organized on the fly with a visual calendar in your Studio.

Go to Content Calendar

Mux input

Upload videos to Mux directly from the studio.

Go to Mux input