website/src/pages/lint/rules/useYield.md
This rule is recommended by Rome.
Require generator functions to contain yield.
This rule generates warnings for generator functions that do not have the yield keyword.
Source: require-await.
function* foo() {
return 10;
}
function* foo() {
yield 5;
return 10;
}
function foo() {
return 10;
}
// This rule does not warn on empty generator functions.
function* foo() { }