How to sort by updated time #846
Unanswered
chenyukang
asked this question in
Q&A
Replies: 1 comment 4 replies
-
Add a temporary hack in QueryRender : tasks.sort(function(a, b) {
const atime = app?.vault.getAbstractFileByPath(a.path);
const btime = app?.vault.getAbstractFileByPath(b.path);
if(atime instanceof TFile && btime instanceof TFile) {
return btime.stat.mtime - atime.stat.mtime;
}
return 0;
} ); |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi, thanks for the great plugin.
My scenario is like this, I write my todos and tasks in all kinds of files, and most of them are not marked with scheduled time and start time, I have a special page with task queries to list them as a board.
My questions is how to sort my tasks in the updated time or created time, I think this is the most natural sorting when there are no more extra meta info.
This is my current query:
Beta Was this translation helpful? Give feedback.
All reactions