useDailyError

useDailyError() : Object

useDailyError returns a stateful representation of the most recent error and nonfatal-error event objects.

Keep in mind that an error event will cause a participant to be ejected immediately from a meeting. If you need to render UI based on the meetingError state, make sure that you don't destroy the callObject instance until you no longer need the error state. This includes updating any props for DailyProvider as we'll destroy the current callObject instance internally in order to setup a new one with the updated props.

Return type

An object with the following properties:

NameTypeDescription
meetingErrorObjectThe most recent event object for the error event.
nonFatalErrorObjectThe most recent event object for the nonfatal-error event.

Sample code