Fork me on GitHub
#pathom
<
2021-05-06
>
Siddharth13:05:57

Hi guys, In a query like this

[:catalogue/id
        {:products/search-results [:product/id :product/title :product/kind]}]
I want :products/search-results 's value sorted by :product/title , can I specify it here ?

Björn Ebbinghaus14:05:42

You can just return the sorted list in your resolver. Alternatively, when you want your order to be dynamic, you can use query parameters: https://blog.wsscode.com/pathom/v2/pathom/2.2.0/connect/resolvers.html#_parameters

Siddharth15:05:49

thanks, I'll try 👍