This site is mobile accessible. Press the "Tap Here" button to use a smaller font-size.
Smartphone icons created by Freepik - Flaticon
The isInteger() method returns true if the argument is an integer.
Otherwise it returns false.
document.getElementById("demo").innerHTML = Number.isInteger(10) + "<br>" + Number.isInteger(10.5);