prefer-await-in-async-return
Prefer explicit await for proven Promise .then calls; the default scope checks direct async returns.
Why
Promise callback chains mix explicit async control flow with nested callbacks, making sequencing and failure handling harder to read.
Fix
Consider awaiting the Promise and returning the transformed value with ordinary async statements. Preserve catch boundaries, callback behavior, and observable scheduling when rewriting manually.
Examples
async function load() { return Promise.resolve(1).then((value) => value + 1);}async function load() { const value = await Promise.resolve(1); return value + 1;}