Plastic js
First of all, there is no concept of int in js. What you want to judge is character type and numerical type.

Suppose the variable is not.

Code:

if(object . prototype . tostring . call(a)= '[object String]'){

//a is a character type.

}

The above code can determine whether A is a string type or a string object.

If (object.prototype.tostring.call (a) =' [object number]') {

//a is a numeric type.

}

The above code can determine whether A is a numeric type or a numeric object.