Browse Source

fix(types): wrong parameter type in onLoadProgress (#538)

WebViewProgressEvent musst be wrapped within NativeSyntheticEvent
manuelblum 5 years ago
parent
commit
5892601c29
1 changed files with 3 additions and 1 deletions
  1. 3
    1
      src/WebViewTypes.ts

+ 3
- 1
src/WebViewTypes.ts View File

@@ -91,7 +91,7 @@ export interface WebViewNativeEvent {
91 91
   lockIdentifier: number;
92 92
 }
93 93
 
94
-export interface WebViewProgressEvent extends WebViewNativeEvent {
94
+export interface WebViewNativeProgressEvent extends WebViewNativeEvent {
95 95
   progress: number;
96 96
 }
97 97
 
@@ -122,6 +122,8 @@ export interface WebViewError extends WebViewNativeEvent {
122 122
 
123 123
 export type WebViewEvent = NativeSyntheticEvent<WebViewNativeEvent>;
124 124
 
125
+export type WebViewProgressEvent = NativeSyntheticEvent<WebViewNativeProgressEvent>;
126
+
125 127
 export type WebViewNavigationEvent = NativeSyntheticEvent<WebViewNavigation>;
126 128
 
127 129
 export type WebViewMessageEvent = NativeSyntheticEvent<WebViewMessage>;