complexity/noThisInStatic
complexity · since 1.3.1
Unsafe autofixRecommended
biome.json
{
"linter": {
"rules": {
"complexity": {
"noThisInStatic": "error"
}
}
}
}class A {
static CONSTANT = 0;
static foo() {
this.CONSTANT;
}
}class B extends A {
static bar() {
super.CONSTANT;
}
}class B extends A {
static ANOTHER_CONSTANT = A.CONSTANT + 1;
static foo() {
A.CONSTANT;
B.ANOTHER_CONSTANT;
}
bar() {
this.property;
}
}class A {
static foo() {
doSomething()
}
bar() {
A.foo()
}
}Examples from the Biome documentation.
ESLint does not have this rule.
Oxlint does not have this rule.
complexity/noThisInStatic
complexity · since 1.3.1
{
"linter": {
"rules": {
"complexity": {
"noThisInStatic": "error"
}
}
}
}Disallow TanStack Query functions that don't return any data.
Disallow using the result of a TanStack Query hook as a React hook dependency.
Disallow rest destructuring and object spread on TanStack Query results.
Disallow unrecognized feature names in media queries.