0

I need to open the website inside my react-native app. Needs to work for both iOS and Android

3
  • Do you need it to be opened inside on of your screens or it could be opened inside external webbrowser? Commented Oct 24, 2019 at 5:20
  • 1
    you can use react-native -webview Commented Oct 24, 2019 at 5:32
  • @KirillKunst I need to open inside in my screens I need to design the header and footer section of that screen Commented Oct 24, 2019 at 5:50

1 Answer 1

1

You can use WebView component: https://facebook.github.io/react-native/docs/webview.html.

Something like this:

import React, { Component } from 'react';
import { WebView } from 'react-native';
class MyWebViewComponent extends Component {
  render() {
     return (
      <WebView
         source={{uri: 'https://google.com'}}
         style={{marginTop: 10}}
      />
    );
  }
}
Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.