Can I use WebView inside a View (react native)?

前端 未结 6 1124
南旧
南旧 2021-02-07 01:13

I am trying to use WebView Component inside View component, for a react native application I am working on. When I embed WebView inside View, I am not seeing the content I am di

6条回答
  •  醉话见心
    2021-02-07 01:40

    For WebView in View, We can use this code for .js and .tsx files in React-native.

    import React, { Component } from 'react';
    import { View } from 'react-native';
    import { WebView } from 'react-native-webview';
    
    export default class WebViewExample extends Component {
     render() {
      return (
       
         
       
       );
      }
    }
    

提交回复
热议问题