@MaBe, the whole came out of a personal conversation that had less in mind to get a formatter going but more so to show the separation of concerns: model / data separate from presentation. Therefore, I would not not extend the Date 'class'... last but not least to prevent future conflicts, when one day Date will extend...
The DateFormatter then just became the icing on the cake - a Kürlauf! ...and freebee... ;)
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
@MaBe, the whole came out of a personal conversation that had less in mind to get a formatter going but more so to show the separation of concerns: model / data separate from presentation. Therefore, I would not not extend the Date 'class'... last but not least to prevent future conflicts, when one day Date will extend...
The DateFormatter then just became the icing on the cake - a Kürlauf! ...and freebee... ;)