Payload and attribution for framework events
Summary: ^ Reviewed By: LukeDefeo Differential Revision: D44496975 fbshipit-source-id: 4f633d0f00239cac16ee332d35755b343d46b124
This commit is contained in:
committed by
Facebook GitHub Bot
parent
6bf099ef79
commit
ce2bfe320b
@@ -37,10 +37,25 @@ export type FrameworkEventMetadata = {
|
|||||||
documentation: string;
|
documentation: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
export type JSON =
|
||||||
|
| string
|
||||||
|
| number
|
||||||
|
| boolean
|
||||||
|
| null
|
||||||
|
| JSON[]
|
||||||
|
| {[key: string]: JSON};
|
||||||
|
|
||||||
|
type Stacktrace = {type: 'stacktrace'; stacktrace: string[]};
|
||||||
|
type Reason = {type: 'reason'; reason: string};
|
||||||
|
type UpstreamEvent = {type: 'upstreamEvent'; eventId: Id};
|
||||||
|
type EventAttribution = Stacktrace | Reason | UpstreamEvent;
|
||||||
|
|
||||||
export type FrameworkEvent = {
|
export type FrameworkEvent = {
|
||||||
nodeId: Id;
|
nodeId: Id;
|
||||||
type: FrameworkEventType;
|
type: FrameworkEventType;
|
||||||
timestamp: number;
|
timestamp: number;
|
||||||
|
payload?: JSON;
|
||||||
|
attribution?: EventAttribution;
|
||||||
};
|
};
|
||||||
|
|
||||||
export type InitEvent = {
|
export type InitEvent = {
|
||||||
|
|||||||
Reference in New Issue
Block a user