File tree Expand file tree Collapse file tree 3 files changed +12
-3
lines changed Expand file tree Collapse file tree 3 files changed +12
-3
lines changed Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " react-native-webview-bridge" ,
3
- "version" : " 0.20.0 " ,
3
+ "version" : " 0.20.1 " ,
4
4
"description" : " React Native WebView Javascript Bridge" ,
5
5
"main" : " webview-bridge" ,
6
6
"directories" : {
Original file line number Diff line number Diff line change @@ -17,6 +17,7 @@ var React = require('react-native');
17
17
var invariant = require ( 'invariant' ) ;
18
18
var keyMirror = require ( 'keymirror' ) ;
19
19
var merge = require ( 'merge' ) ;
20
+ import resolveAssetSource from 'resolveAssetSource' ;
20
21
21
22
var {
22
23
ReactNativeViewAttributes,
@@ -110,11 +111,15 @@ var WebViewBridge = React.createClass({
110
111
domStorageEnabled = this . props . domStorageEnabledAndroid ;
111
112
}
112
113
114
+ let props = { ...this . props } ;
115
+ const source = resolveAssetSource ( props . source ) ;
116
+ delete props . source ;
117
+
113
118
var webView =
114
119
< RCTWebViewBridge
115
120
ref = { RCT_WEBVIEWBRIDGE_REF }
116
121
key = "webViewKey"
117
- { ...this . props }
122
+ { ...props }
118
123
style = { webViewStyles }
119
124
onLoadingStart = { this . onLoadingStart }
120
125
onLoadingFinish = { this . onLoadingFinish }
Original file line number Diff line number Diff line change 17
17
var React = require ( 'react-native' ) ;
18
18
var invariant = require ( 'invariant' ) ;
19
19
var keyMirror = require ( 'keymirror' ) ;
20
+ import resolveAssetSource from 'resolveAssetSource' ;
20
21
21
22
var {
22
23
ActivityIndicatorIOS,
@@ -174,15 +175,18 @@ var WebViewBridge = React.createClass({
174
175
}
175
176
} ;
176
177
177
- const props = { ...this . props } ;
178
+ let props = { ...this . props } ;
179
+ const source = resolveAssetSource ( props . source ) ;
178
180
delete props . onBridgeMessage ;
179
181
delete props . onShouldStartLoadWithRequest ;
182
+ delete props . source ;
180
183
181
184
var webView =
182
185
< RCTWebViewBridge
183
186
ref = { RCT_WEBVIEWBRIDGE_REF }
184
187
key = "webViewKey"
185
188
{ ...props }
189
+ source = { source }
186
190
style = { webViewStyles }
187
191
onLoadingStart = { this . onLoadingStart }
188
192
onLoadingFinish = { this . onLoadingFinish }
You can’t perform that action at this time.
0 commit comments