Skip to content

Accepted parameters for function not documented #2413

@stairjoke

Description

@stairjoke

Issue with Reference
The page https://getkirby.com/docs/reference/objects/toolkit/collection/sort states:

Sorts the elements by any number of fields

But there is no information on usable parameters. When digging deeper, it becomes clear the function sortBy()-is an alias, and its page contains that the function takes "mixed" arguments.

Based on this documentation, usage of this function is unclear. Should I pass a string, similar to the sorting options in blueprints? Should I pass an array of options—but what options?

Expected
A table giving information about the arguments the function expects, what they mean, and an example of its use.

Screenshots
Table of Parameters on alias function:
Image
This table, unfortunately, is also useless.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions