Things I have tried
Here is where I’ve gotten as far as the code goes, but is not working/is breaking.
for (let group of dv.pages("#TFT/Character and #TFT").where(b => b.Seer).groupBy(p => p.Seer)) {
dv.header(2, group.key);
dv.table(["Photo", "Name", "Status"],
group.rows
.map(k => ['![photo|90](" +' k.photo '+ ")', k.file.link, k.Status]))
}
What I’m trying to do
I’m trying to add photos to a table rendered using DataviewJS. I’ve figured out how to do this in the standard dataview query language:
TABLE WITHOUT ID
("![photo|90](" + photo + ")") as Photo, file.link as "Name", Age, Summary, Status
FROM #TFT/Character
WHERE contains(Role, "Hero")
SORT file.ctime asc
But haven’t been able to replicate the behavior in JS (I’m admittedly not too well-versed in Javascript). You can see the code snippet that I’ve tried (which is not valid/working/breaks) above.
Any help would be greatly appreciated!