Expose cljs date formatting functions into advanced queries

As a result of my efforts to create an advanced query to show scheduled events (see my question Query for scheduled events with custom view and date formatting?) I noticed that dates are usually stored in properties as integers (eg: 20220416), but if I want to create a link from that date to the corresponding journal page, I need to transform that integer (20220416) into the textual representation “2022 -4-16 Saturday”. Moreover, this text depends indeed on the user settings.

Apparently there is no way to perform this transform inside an advanced query. However, the required function is already implemented in the clsj function int->journal-title which is part of fontend/date.cljs (logseq/date.cljs at c370a961aafa81d23f48d463080fce71f48a594f · logseq/logseq · GitHub)

Unfortunately that function cannot be used from code in an advanced query. User Darwis in Discord showed me that a minimal change is required in the code to expose this function and make it usable from advanced queries. (Discord)

I think it would be very useful to have this function accesible (and perhaps other related ones, such as journal-title->int to make easier closing the gap between the different ways dates are represented internally in logsea.