Considering the below, it looks like the call with implicit parameter is like a static call, the initialized property becomes undefined.
Is this expected? If yes, why?
export class MyClass {
private prop: string;
constructor(){
this.prop = 'value!';
}
foo(){
// This works
something.subscribe((x: string) => this.bar(x));
// This doesn't
something.subscribe(this.bar);
//...
}
bar(z: string) {
console.info(this.prop);
// Is undefined with second call
}
}