typeOf is a function to get the type of a javascript object.