onExtensionErrorWithContext property

void Function(ExtensionContext context, int error, String message)? onExtensionErrorWithContext
final

Occurs when the extension runs incorrectly.

In case of extension enabling failure or runtime errors, the extension triggers this callback and reports the error code along with the reasons.

  • context The context information of the extension, see ExtensionContext.
  • error Error code. For details, see the extension documentation provided by the extension provider.
  • message Reason. For details, see the extension documentation provided by the extension provider.

Implementation

final void Function(ExtensionContext context, int error, String message)?
    onExtensionErrorWithContext;