Skip to content

sort doesn't infer in simple case #338

@wclr

Description

@wclr
  1. I believe sort should always return type of passed array:
  2. Be able to check typings in inner comparator
    type A = { x: number }    
    const list: A[] = [{ x: 1 }, {x: 2}]
    const sorted = R.sort(R.ascend(R.prop('y')), list)

image

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions