DEV Community

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

Collapse
 
___prototype profile image
Karakabakov

this is integral part of JavaScript and replacing it with a third-party library, in my opinion, is out of question.

I know it's not a big library but still it contributes to the bundle.

Cost of Javascript

Collapse
 
joelnet profile image
JavaScript Joel

The dependency and bundle cost is absolutely a cost that should be weighed when considering all packages. More people should think this way.

NULL is also an integral part of JavaScript. NULL has now been labeled the Billion dollar mistake. How much will THIS cost us?

Collapse
 
___prototype profile image
Karakabakov

All programming languages have quirks.. By following best practices, making regular code reviews, code refactoring and actually learning when/how to use THIS most of the problems can be avoided.

And what about those problems that survive all of the above?
Well in that case we have automated tests, unit tests and plain old manual tests.

Thread Thread
 
joelnet profile image
JavaScript Joel

"Because that is the way we have always done it" is not a valid excuse.

"We put additional checks in to catch these problems" is backwards. You are treating the symptoms, not the cause. Write your code in a way that those problems are unable to exist.

If NULL is the Billion dollar mistake and this is magnitudes more complex than NULL. How much is this costing us?

It's time to think outside the brackets { }.

nothis