Hello everyone. I tried everything to solve it my own but my js knowledge seems to be to limited to understand what is going on. Hope you can help me ![]()
What I’m trying to do
My dataviewjs inline query is supposed to spit out a list of notes that contain a certain link value in their frontmatter.
As a dataview block it works fine and looks like this:
LIST
WHERE contains(up, [[Test Note]])
SORT file.name ASC
LIMIT 10
Translated to dataviewjs inline query I get an error message
TypeError: p.up.contains is not a function. My code is (to increase readability I split it on multiple lines):
$=dv.list(dv.pages(‘’)
.where(p => p.up.contains(“[[Test Note]]”) )
.sort(f=>f.file.name,“asc”)
.limit(10)
.file.link)
Things I have tried
I’m sure that the faulty line starts with .where
I studied the Dataview Code Reference up and down but couldn’t find a solution there ![]()
Any ideas?
Some background information
This issue became important to me after implementing the Dashboard++. There dataviewjs inline queries are used. As I find it easier to create a dataview block, I tried to replace them. BUT subsequently the layout of the dashboard was a mess because the output list items were on the first level instead the expected second level. So, for the case that I won’t get the dataviewjs query working probably I need a solution how to indent the list items of the dataview block query.