Chase AdamsChase Adams
AboutContentPromptsPrototypesNewsletter

Get list items containing a tag with Obsidian and Dataview

Essays and updates on product, engineering, and AI by Chase Adams.

1 minute read

I use Obsidian for interstitial journaling and wanted to list all of my specific list items containing the #journal tag.

This DataviewJS snippet gets all items where they include1 a specific tag (#journal):

//```dataviewjs
dv.list(dv.pages().file.lists.where(t => t.text.includes("#journal")).map((t ) => t.text))
//```

Being able to query individual list items is a power boost for anyone using Obsidian for interstitial journaling and keeping their journal entries in a daily note!

Footnotes

  1. It doesn't have to be a tag, includes is a JavaScript string function, which means you could @ mention something, filter by some thing that could be queried with a Regular Expression or even link to another file! ↩

First Cohort
No Coding Experience Required

Build Your Website with AI—No Code Required

Learn to create and deploy professional websites using ChatGPT and Claude. Go from complete beginner to confident website builder.

Start Building Today

Post Details

Published
Oct 21, 2022
Share
ChatGPT

Latest Posts

Rescuing Your Claude Conversations When You Rename Projects

Rescuing Your Claude Conversations When You Rename Projects

If you've ever renamed a project folder and watched weeks of Claude Code conversations vanish, here's a script to help you move directories without losing your conversations.

AboutAI Workflow SpecContentStacksNewsletterPromptsRSS