benjypng/logseq-powerblocks-plugin

[Feature Request]: Add syntax to query properties

Closed this issue · 3 comments

Plugin Version

0.0.32

Logseq Version

current as of today

Request

Thank you for this genius plugin, it’s just what I’ve been looking for.

I would love a syntax that allows us to query the values of a page's properties. The default could be the properties of the current page, but could be expanded to allow a user to also specify another page's properties to query.

Make my dreams come true?

Sure! So let's say we have a [[page 1]] with a page property of DOB:: 1/1/2000. I’d love for a template to insert the DOB as needed.

So, for example, the syntax could look like: I was born on <%PROPERTY: [[page 1]] DOB%>. And it would resolve to I was born on 1/1/2000. So the reference would require the page name and a specific property of the page.

I think you already have the start of this functionality with the syntax <$CURRENTPAGENAME%>, but being able to reference a page's properties would allow the creation of very sophisticated templates for things like emails, letters, and other repetitive information.

Thanks again for considering this feature!

This is available in the latest update. For your example, separate your page with a comma, e.g.
I was born on <%GETPROPERTY:[[page 1]],DOB%>.