How do you render a list of callouts containing mulitple fields in dataview?

Things I have tried

This works in plain old dataview

LIST WITHOUT ID ">[!Info]
" + attribute_a 
+ "<br><br>" +
"Attribute b: "  + attribute_b + "<br><br> " + attribute_c 
 

What I’m trying to do

How do I write the above in dataviewjs?

I got this, but it doesn’t work. I don’t really know what I’m doing…

let pages = dv.pages()

for (let page of pages){
		dv.list(page.rows.map(p => ">[!Info] " +  p.attribute_b +  "<br><br>"  + "Attribute b: "  + p.attribute_b + "<br><br> " + p.attribute_c ))
		
}

I figured it out. You have to add ‘\n’ after the callout…

let pages = dv.pages()

for (let page of pages){
		dv.list(page.rows.map(p => ">[!Info] \n" +  p.attribute_b +  "<br><br>"  + "Attribute b: "  + p.attribute_b + "<br><br> " + p.attribute_c ))
		
}

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.