js how to test what data type somethingis code example Example: check data type in js var x = "Hello World"; typeof x; // "string"