How to setup Graph View to show content with matching tags?

1 replies
Last updated: Nov 30, 2020
Hi Smart People! Question about the Graph View:
Is there a doc showing how to setup the graph to show content with matching tags?
AI Update

I think there might be some confusion here! Based on your question and the SEO context you mentioned, it looks like you're asking about Obsidian's Graph View, not Sanity's. Obsidian and Sanity are different tools:

  • Obsidian is a note-taking app with a graph visualization feature for linking notes
  • Sanity is a content management platform (CMS) for structured content

Sanity doesn't currently have a built-in "Graph View" feature like Obsidian does. However, if you're looking for ways to visualize or work with relationships between content in Sanity, here are some options:

For visualizing content relationships in Sanity:

  1. References in the Studio - You can see document references in the Studio interface when you use reference fields, but there's no graph visualization built-in

  2. Custom plugins - You could build a custom Studio plugin to visualize document relationships as a graph using libraries like D3.js or vis.js

  3. GROQ queries - You can query related content using GROQ with references and use the results to build your own visualization

If you're actually looking for Obsidian documentation on filtering the Graph View by tags, you'll want to check help.obsidian.md - specifically their documentation on search operators and the tag: syntax for filtering nodes in the graph by color, groups, and matching tags (including nested tags with exact match using quotes).

If you are asking about Sanity and want to work with tagged content or document relationships, feel free to clarify your use case and I can point you to relevant Sanity features!

Show original thread
1 reply
I'm not sure that's possible at the moment. You can use GROQ to filter down the documents you want to show. More info and source code here, if you want to adapt it: https://github.com/sanity-io/sanity-plugin-graph-tool

Sanity – Build the way you think, not the way your CMS thinks

Sanity is the developer-first content operating system that gives you complete control. Schema-as-code, GROQ queries, and real-time APIs mean no more workarounds or waiting for deployments. Free to start, scale as you grow.

Was this answer helpful?