The this keyword is used to reference the current function/object context. The problem is, a function can easily be 'detached' from the object it was originally defined as a method of then the this keyword no longer references what you thought it should and errors occur.
Tweet
SaveShareSend
Tags: javascript
Comments
ilazarte replied ago:
this. is a major headache. in javascript, half of debugging is finding out what this. is! arg. scoping issues are definitely some the things i would really change about js if i could.
sproketboy replied ago:
Reason #786 why JavaScript is lame. :(
rd112681 replied ago:
A mention of javascript in the title would have been appreciated.
estacado replied ago:
Even until today, I still don't fully understand how to use "this".
Voters For This Link (10)
Voters Against This Link (0)