JavaScript type checking.