Get list items with a tag and display without the tag

Language:: Plugin - Dataview
Program:: Obsidian
URL:: Reddit - Dataview Lines with Tag

Summary

Use dataview and regard to get and show items with a tag

Code


TABLE WITHOUT ID string(link(rows.file.link, rows.title)[0]) AS class, regexreplace(list(rows.L.text), "#exam", "") AS "exam"
FROM "3_semester"
FLATTEN file.lists AS L
WHERE contains(L.tags, "#exam")
GROUP BY file.link

Explanation

I use this snippet to list lines tagged with β€˜#exam’ in my folder "3_semester", which I adapted fromΒ this discussion. To show the tag too just remove the regexreplace().

Result

class πŸ”₯
Blindsight
    • Awesome passage on Technology
    • This seems like the thesis to the entire book here, a lot of ideas baked into this passage, damn!
The Dawn of Everything
    • hell yea!
    • Love this, beautifully said

up:: πŸ§ͺ Code Diary