I am trying to sort a query (or an array) by the names of a related object and display them in an object-table in this order. Let’s call the object A and the related object B. For some A objects, it does not have a B relationship. If A.B == null, these should go at the top, else I want to sort on A.B.name alphabetically.
I don’t think this can be accomplished with an orderBy on the query, so I’m trying to get back an array and then use Array.sort(). After messing with this a while and outputting the whole process to the console, it looks like the object-table is simply not respecting the sort order when rendering the array. Any suggestions on how to best accomplish this?