The body of the catch statement.
Even if the
catchis triggered, and even if an exception is thrown in thecatch, thefinallywill still be executed.
It can be an asynchronous function or a synchronous function.
OptionalfinallyThe body of the finally statement.
To avoid difficult-to-handle situations, ensure that the
finallystatement does not throw an exception. (But if thefinallystatement throws an exception, it can still be caught by the outertry-catch.)Even if the
catchis triggered, and even if an exception is thrown in thecatch, thefinallywill still be executed.It must be a synchronous function.
The body of the try statement.
It can be an asynchronous function or a synchronous function.
The options for the
try-catch[-finally]expression.