Skip to content

Sorting entities in views/groups #1155

Answered by skypjack
menganha asked this question in Q&A
Discussion options

You must be logged in to vote

If you added N elements of the same type in a tick, the last method would sort N times a pool vs a single time of the original approach.
If you really want to lazy sort things on demand, use signals or another approach to raise a flag and check this flag before sorting.
This way you know that you're only sorting once and when needed. This is probably the best of the two worlds.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@menganha
Comment options

Answer selected by menganha
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
discussion it sounds interesting, let's discuss it
2 participants