Chase Adams
Chase Adams

Filter List Items by Inline Tag in Obsidian with DataviewJS

A DataviewJS snippet to query all list items — bullets, tasks, or journal entries — that contain a specific inline tag across your entire Obsidian vault.

1 minute read

I use 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 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 string function, which means you could @ mention something, filter by some thing that could be queried with a or even link to another file! ↩