_.isNumber(NaN) returns true

· GitHub ·

1 min read Original article ↗

Description

As NaN stands for "Not a Number" the isNumber check in this case seems like it should return false. I notice from other discussions that this is in fact on purpose. Maybe the documentation should reflect this fact explicitly.

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

    Projects

    No projects

      Milestone

      No milestone

        Relationships

        None yet

        Development

        No branches or pull requests

        Issue actions