Skip to content

Support sorting by nested properties #5

Description

@ohadschn

The current sorting code starts with the following:

rows.sort (a,b) =>
        aVal = ko.utils.unwrapObservable a[@sortField()]
        bVal = ko.utils.unwrapObservable b[@sortField()]

As such, only flat properties of the row object can be used for sorting.
For example, suppose my row looks like this:

{
    foo:
    {
        bar: "foobar"
    }
}

It would have been nice to be able to sort by foo.bar

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions