apollo-kotlin icon indicating copy to clipboard operation
apollo-kotlin copied to clipboard

ErrorBoundary

Open sonatard opened this issue 1 year ago • 1 comments

Use case

Place an ErrorBoundary at the top level of your component hierarchy. This allows it to catch errors thrown by lower-level components and handle these errors with a fallback mechanism.

React docs https://ja.react.dev/reference/react/Component#catching-rendering-errors-with-an-error-boundary

Jetpack Compose implementation https://docs.soil-kt.com/guide/query/hello-query#step-4-compose-runtime

Describe the solution you'd like

This eliminates the need for implementing error handling in individual components.

Reference

I created this issue to Jetpack Compose. https://issuetracker.google.com/issues/342247580

sonatard avatar May 23 '24 02:05 sonatard

Related to https://github.com/apollographql/apollo-kotlin/issues/5914 and could also be complementary to the new nullability directives 🙏🏻

bignimbus avatar May 23 '24 13:05 bignimbus