Skip to content

AngularJS IFilterFunc too restrictive #5931

Closed

Description

@rcollette

IFilterFunc in angular.d.ts appears to require an array as the first parameter and it also specifies that the return type is the same as the input type. However, it is possible for the first parameter to not be an array and the output type may be different than the input type.

See this plnkr for an example of a single number being used as input and the return type of the filter function being a string.

http://plnkr.co/edit/xwMZe5g9YuYNhW2obMjG?p=preview

Activity

  1. albv commented on Sep 21, 2015

    @albv
  2. added a commit that references this issue on Sep 22, 2015
    d58f56a
  3. use-strict commented on Sep 22, 2015

    @use-strict
    Contributor

    Already created fix in #5948

  4. use-strict commented on Oct 15, 2015

    @use-strict
    Contributor

    Can someone close this? :)

  5. vvakame commented on Oct 16, 2015

    @vvakame
    Member

    thanks!

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions