4 ms·
The important thing is that the ES7 property initializer with the arrow syntax binds the function's "this" to the instance.
by eschutte2 9y ago
The important thing is that the ES7 property initializer with the arrow syntax binds the function's "this" to the instance.
- lwansbrough 9y agoI understand that, but that’s not necessarily acceptable if it makes debugging a nightmare. Apparently there is also a bind decorator, which I think is nicer than either of the other methods, because it is explicit but also clear, and without the verbosity.