Is there a way to avoid always having to attach a "this" to referencing private Component variables or functions?
For example, the following will cause a "Cannot find name" error on "foo"
export class SomeComponent {
private foo = 5;
someMethod(){
console.log(foo);
}
}
To fix, I need to attach a "this" to the foo variable, as in:
console.log(this.foo);
I'm all for strong identification of variables, but this seems overly strict given the smaller size of most Angular components.