Closed
Description
We want to unify our compilation flags inside and outside Google for Angular projects. We found that this flag improves readability by asking you to explicitly write return undefined
in the scenarios where it can happen like:
function f() {
if (someCond()) {
....
return x;
}
}
The fix is usually to just write:
function f() {
if (someCond()) {
....
return x;
}
return undefined;
}
or rethink the control flow.