Skip to content

Glossary: React Native

try / catch / finally

Also written: try/catch, catch, finally

JavaScript's way to handle failures: code in `try` runs, `catch` runs if it throws (for example to show a friendly message), and `finally` runs either way, such as to turn a loading flag off.

Where the book teaches it

Related terms

as (type assertion)