discordSort

export function discordSort<Key, Value extends { rawPosition: number; id: Snowflake }>( collection: ReadonlyCollection<Key, Value>,): Collection<Key, Value>;
export function discordSort<Key, Value extends { rawPosition: number; id: Snowflake }>( collection: ReadonlyCollection<Key, Value>,): Collection<Key, Value>;
Sorts by Discord's position and id.
NameConstraintsOptionalDefaultDescription
KeyNoNone
Value{ rawPosition: number; id: Snowflake }NoNone
NameTypeOptionalDescription
collectionReadonlyCollection<Key, Value>NoCollection of objects to sort