You might want to have a look at this answer:
Can we omit parentheses when creating an object using the "new" operator?
Basicly new Date
is equivilent to writing new Date()
though you might prefer to use new Date()
for consistency, since functions and constructors are so similar in JavaScript and the parentheses-less syntax is definitely illegal for function invocation.