|
|
|
|
|
by v413
3997 days ago
|
|
With the introduction of arrow function you won't need to use .bind(this) as arrow functions capture in their lexical scope the variables/keywords: this, arguments, super. e.g. setTimeout(function(){alert(this.a)}.bind(this)); becomes simply setTimeout(() => alert(this.a)); |
|