Skip to content

isNaN() should accept any value (in type definition) #13227

Closed
@KostyaTretyak

Description

@KostyaTretyak

TypeScript Version: 2.1.4

Code

isNaN('222');

Expected behavior:
Works without error

Actual behavior:
Throw error:

[ts] Argument of type '"222"' is not assignable to parameter of type 'number'.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Working as IntendedThe behavior described is the intended behavior; this is not a bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions