I tried to show content using webview but screen shows me white screen before webpage load complete .
I want to change color white to #131416. but style option doesn’t work.
how can I fix this?
<WebView
ref={webViewRef}
source={{
uri: currentUrl.current,
}}
style={{ flex: 1, backgroundColor: "#131416" }}
onLoadStart={handleOnLoadStart}
javaScriptEnabled={true}
allowFileAccess={true}
onMessage={handleMessage}
onNavigationStateChange={setNavigationState}
userAgent={userAgent}
onShouldStartLoadWithRequest={onShouldStartLoadWithRequest}
scrollEnabled={true}
domStorageEnabled={true}
startInLoadingState={true}
onLoadEnd={handleOnLoadEnd}
onContentProcessDidTerminate={() => {
RNRestart.restart();
}}
/>
I tried change styles and used renderLoading props but doesn’t work.
New contributor
devdean is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.