DEV Community

Discussion on: Rethinking JavaScript: The complete elimination and eradication of JavaScript's this.

Collapse
 
lightest profile image
Nikita Agafonov

This is nuts. Learning the properties of the language is part of the deal. Rules of using this are not hard and actually pretty straightforward. We'd be better off focusing on real world problems instead fixing imaginary "DnD rules".

Collapse
 
joelnet profile image
JavaScript Joel

If people actually understood the rules of this, Classes wouldn't have been added into JavaScript. This confuses many people as they expect them to work the same way they do in other OO languages like C#.

nothis is not cosmetic. This solves real world problems, like never having to debug this.

Every dev I know has written console.log(this) to debug this. What if you never had to... ever again...?