mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Introduce HasJavascriptExceptionMetadata interface
Summary: @public Introduces `HasJavascriptExceptionMetadata`, a thin interface to be implemented by all RN (Android) exception classes that represent JavaScript errors (primarily `JavascriptException` and any subclasses). Also adds a builder-style API for setting the `extraDataAsJson` field on `JavascriptException` instances. Reviewed By: abhinavbatra Differential Revision: D16090574 fbshipit-source-id: 427a0d371f1cb4e6fe2e62a91db7857a191fdb8c
This commit is contained in:
committed by
Facebook Github Bot
parent
f7695e0183
commit
6fb1690de1
+16
@@ -0,0 +1,16 @@
|
||||
/**
|
||||
* Copyright (c) Facebook, Inc. and its affiliates.
|
||||
*
|
||||
* <p>This source code is licensed under the MIT license found in the LICENSE file in the root
|
||||
* directory of this source tree.
|
||||
*/
|
||||
package com.facebook.react.common;
|
||||
|
||||
import javax.annotation.Nullable;
|
||||
|
||||
/** A JS exception carrying metadata. */
|
||||
public interface HasJavascriptExceptionMetadata {
|
||||
|
||||
@Nullable
|
||||
String getExtraDataAsJson();
|
||||
}
|
||||
Reference in New Issue
Block a user