The article explores the intricacies of the 'this' keyword in JavaScript, emphasizing its contextual nature. Initially seen as a complex aspect of web development, the author reflects on their journey from confusion to clarity regarding 'this'. They assert that understanding 'this' is fundamental to JavaScript's structure, where functions are bound to objects. The author encourages developers to embrace the nuances of 'this' as part of learning JavaScript, making it a crucial part of effective coding practices.
For me, the trouble was always that this is contextual, but that context isn't meaningful to us developers so much as it's meaningful to JavaScript.
Once you've got a handle on those two aspects, this is- well, still a little weird, but the knowable kind of weird.
At a high level, the object bound to a function makes sense when you frame it in terms of the essential nature of JavaScript: objects with methods referencing objects with methods.
I think I've gotten a pretty good handle on this. I mean, give or take an emotional support console.log every so often.
Collection
[
|
...
]