2 ms·
console.log(today.getDay()) // prints 1 assuming there was a setDay, and you invoke: today.setDay(3) should today now be: 21/9/2016 or 14/9/2016 or 19/10/201
by CyberFonic 10y ago
console.log(today.getDay()) // prints 1
assuming there was a setDay, and you invoke:
today.setDay(3)
should today now be: 21/9/2016 or 14/9/2016 or 19/10/2016 or 19/9/2040 or ... ?
I think you can see that unlike the other setters, setDay would not have an "obvious" implementation.