Source : React Native Check Value Is Number Or Not Using isNaN() Validation
This tutorial explains how to check value is a number or not a number using isNaN() function in react native application. The function isNaN() is used to check the value of any variable or state is a number or not. In this example we will check input is a number or not.
To Check Value is a Number or Not :
isNaN(Pass the Value to check); //It will return true if not a number else false
Note : If the value do not contain the number then it will return True and if the value contain number value then it will return us False.
Top comments (1)
Hi @skptricks
We encourage the entire article to be published on DEV.to (if you have proper rights), with a linkback if appropriate. Otherwise, we recommend original material, such as an original commentary on the article.
From the Terms of Use:
Posts that are simply intended to encourage readers to view an external resource are discouraged.
Thank you.