I just read this article on W3Schools about type conversion in JS. There stands:
There are 3 types of objects:
- Object
- Date
- Array
This confused me because to my knowledge there isn't any difference between Date
objects and any other object (typeof (new Date())
returns "object"
). First I thought that it's special because it contains native code, but there are dozens of functions with native code.
Is this article wrong? Or could anybody tell my why the Date
object is so extraordinary that it's considered a separate type of object?