I am making an library in my obsdian and and i want put the cover of books in dataview without necessarily using {{coverUrl}} as a property like i use on template seen below
This way the cover is displayed right below the template without an “cover” property, but i want make this in dataview and the only way that i know is making this is making an “cover” property and use the ("") as Cover as parameter in dataview.
I tried made this way:
("") as Capa
Ps:. I’m brazilian and i don’t know english well, so some informations are in portuguese
Dataview uses metadata like properties, so your options will be limited.
One thing you could do is save the cover image into your Obsidian vault and give it the same name as your note title (or some other metadata on your note that is unique). Then, in your dataview query you could use embed(link(file.name + ".png","150")) as Cover. You would have to save your book covers with the same file type; I chose PNG but you could use JPG if you preferred.
I think it would be easier to save the coverURL as a property.
Edit:
I may have misread your question. Dataview doesn’t use curly braces for variables. If you have a property with the cover URL, you should be able to do something like this:
("") as Capa
I wasn’t able to get that syntax to work, so you can try the embed(link())function.
TABLE WITHOUT ID file.link AS "Title",
embed(link(banner, "150")) AS "Cover"
FROM "KB/Obsidian/Plugins"
WHERE banner
I have Dataview plugin installed AND Pixel-Banner
add banner to meta property: banner
Done
As a side note, Google uses AI for over 25% plus of coding now, instead of posting here, use Perplexity, anthropic, mistral le chat to write the dataview queries for you.
life is wayyy too short! use it in cursor, maybe even in Obsidian with local gpt and ollama!
and cant wait till devs start using more AI to create more awesome plugins, Obsidian is way superior to Notion or OneNote, flow whatever!
Hope this helps someone