4 ms·
Definitely not the focus! The extends/super keywords are just "shortcuts" to normal prototypal inheritance. I just thought that the time machine example was pre
by alongub 12y ago
Definitely not the focus! The extends/super keywords are just "shortcuts" to normal prototypal inheritance. I just thought that the time machine example was pretty cool :)
- nilliams 12y agoYep, same as CoffeeScript. All CoffeeScript's `class` stuff does is set up the prototype chain for the exact way that every JS dev under the sun does their manual prototype stuff. AFAICT you're doing the same thing you're just making it look more function-y. Not that I hate that I just think it's an incredibly minor semantic difference, and I probably slightly prefer the outright 'call it a class' approach of CoffeeScript as it feels more like calling a spade a spade.