Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
jrockway
on April 24, 2011
|
parent
|
context
|
favorite
| on:
Finally someone makes sense of JavaScript's this k...
Aha! I also do "var self = this;" but feel really bad about it, like I'm missing something obvious about the language. I guess I'm not.
msy
on April 24, 2011
[–]
You're not alone, every time I do this I feel like I'm going wrong somewhere. I know it's avoidable via binding/currying/proxying but often those solutions end up looking uglier and are harder to follow.
Consider applying for YC's Winter 2027 batch!
Applications
are open till November 2.
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: