3 ms·
I personally find that manual return type annotations actually prevent some errors. A common case: I forget the return statement in one branch, and TypeScript i
by codeflo 6y ago
I personally find that manual return type annotations actually prevent some errors. A common case: I forget the return statement in one branch, and TypeScript is happy to infer something like number|undefined as the return type.