In modern JavaScript, this
should not appear outside of an class.
function foo () {
this.bar;
}
function Foo(name) {
this.name = name;
}
class Foo {
foo() {
function bar() {
this.baz;
}
}
}
class Foo {
foo() {
this.name;
}
}
class Foo {
foo() {
const bar = () => {
this.name;
}
}
}
no-this-outside-of-class
No response
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too