JavaScript From The Start


JavaScript typeof Operator


Hide/Show description

JavaScript has a typeof operator that you can use to find the data type of your variables. However, while it works consistently with Primitive types - String, Boolean, and Number, it can be a little less predictable when working with complex and compound data types.