Quite often I find myself writing
await Promise.resolve() in an async function, particularly when writing tests for other async functions but also sometimes when I just want to delay execution until the next tick. The thing about this is that I know I can write
await 1 or
await (expression) for much the same effect. However, I feel like the intention is not as clear with these other things, and I work with and mentor junior engineers who I know would be confused by it because you're awaiting a non-asynchronous value. So I choose the overly verbose option for increased clarity.
Would it be feasible to make the expression
await; work on its own as syntactic sugar for