document dsl rules for advance queries
Nobody has claimed this yet.
- Dominant language
- Clojure
- Stars
- 192
- Forks
- 95
- PR merge metrics
- No merged PRs in 30d
Description
I was trying to understand what's the actual meaning of between, but I can't find the documentation. It seems to be the task's journal date, but these queries made me think it's the referenced journal date: (Tasks referencing due dates ...)
Then I found the definition here https://github.com/logseq/logseq/blob/master/deps/db/src/logseq/db/rules.cljc
:between
'[(between ?b ?start ?end)
[?b :block/page ?p]
[?p :block/journal? true]
[?p :block/journal-day ?d]
[(>= ?d ?start)]
[(<= ?d ?end)]]
So it's indeed the task's journal date and the queries above are wrongly explained. I think it might be better to add documentation for these rules, and fixup the examples.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the Advanced Queries section in the linked docs page and compare its examples with the :between rule in deps/db/src/logseq/db/rules.cljc. Clarify the documented meaning of the affected rules and correct the examples so they match the rule definitions. Done means the rules are documented and the referenced queries are no longer misleading.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- clojure
- Domain
- documentation
- Issue type
- Documentation
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100