mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
47 lines
29 KiB
HTML
47 lines
29 KiB
HTML
<!doctype html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width,initial-scale=1">
|
|
<meta name="generator" content="Docusaurus v2.0.0-alpha.66">
|
|
<link rel="alternate" type="application/rss+xml" href="/blog/rss.xml" title="React Native Blog RSS Feed">
|
|
<link rel="alternate" type="application/atom+xml" href="/blog/atom.xml" title="React Native Blog Atom Feed">
|
|
<link rel="preconnect" href="https://www.google-analytics.com">
|
|
<script>window.ga=window.ga||function(){(ga.q=ga.q||[]).push(arguments)},ga.l=+new Date,ga("create","UA-41298772-2","auto"),ga("send","pageview")</script>
|
|
<script async src="https://www.google-analytics.com/analytics.js"></script>
|
|
<link rel="preconnect" href="https://www.google-analytics.com">
|
|
<link rel="preconnect" href="https://www.googletagmanager.com">
|
|
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-41298772-2"></script>
|
|
<script>function gtag(){dataLayer.push(arguments)}window.dataLayer=window.dataLayer||[],gtag("js",new Date),gtag("config","UA-41298772-2",{})</script>
|
|
<link rel="search" type="application/opensearchdescription+xml" title="React Native" href="/opensearch.xml">
|
|
<script src="https://cdn.jsdelivr.net/npm/focus-visible@5.2.0/dist/focus-visible.min.js" defer="defer"></script>
|
|
<script src="https://snack.expo.io/embed.js" defer="defer"></script><title data-react-helmet="true">_getting-started-macos-ios · React Native</title><meta data-react-helmet="true" property="twitter:image" content="https://reactnative.dev/img/logo-og.png"><meta data-react-helmet="true" name="twitter:image:alt" content="Image for React Native"><meta data-react-helmet="true" name="docsearch:language" content="en"><meta data-react-helmet="true" name="docsearch:version" content="0.63"><meta data-react-helmet="true" name="docsearch:docusaurus_tag" content="docs-default-0.63"><meta data-react-helmet="true" property="og:image" content="https://reactnative.dev/img/logo-og.png"><meta data-react-helmet="true" name="twitter:card" content="summary"><meta data-react-helmet="true" name="twitter:image" content="https://reactnative.dev/img/logo-og.png"><meta data-react-helmet="true" property="og:title" content="_getting-started-macos-ios · React Native"><meta data-react-helmet="true" name="description" content="Installing dependencies"><meta data-react-helmet="true" property="og:description" content="Installing dependencies"><meta data-react-helmet="true" property="og:url" content="https://reactnative.dev/docs/_getting-started-macos-ios"><link data-react-helmet="true" rel="shortcut icon" href="/img/favicon.ico"><link data-react-helmet="true" rel="preconnect" href="https://BH4D9OD16A-dsn.algolia.net" crossorigin="anonymous"><link data-react-helmet="true" rel="canonical" href="https://reactnative.dev/docs/_getting-started-macos-ios"><link rel="stylesheet" href="/styles.fccefeba.css">
|
|
<link rel="stylesheet" href="/main.ca40cabd.css">
|
|
<link rel="preload" href="/styles.07d522c6.js" as="script">
|
|
<link rel="preload" href="/runtime~main.7f243cb9.js" as="script">
|
|
<link rel="preload" href="/main.5e05a427.js" as="script">
|
|
<link rel="preload" href="/1.ba9ce8bd.js" as="script">
|
|
<link rel="preload" href="/2.58cb5d3d.js" as="script">
|
|
<link rel="preload" href="/1f391b9e.a824c215.js" as="script">
|
|
<link rel="preload" href="/943.8b024446.js" as="script">
|
|
<link rel="preload" href="/ee5b3385.b4fff665.js" as="script">
|
|
<link rel="preload" href="/17896441.0c201679.js" as="script">
|
|
<link rel="preload" href="/f612f9dd.9478b041.js" as="script">
|
|
<link rel="preload" href="/f88ba1af.66e13c4c.js" as="script">
|
|
</head>
|
|
<body>
|
|
<script>!function(){function t(t){document.documentElement.setAttribute("data-theme",t)}var e=function(){var t=null;try{t=localStorage.getItem("theme")}catch(t){}return t}();t(null!==e?e:"light")}()</script><div id="__docusaurus">
|
|
<nav class="navbar navbar--fixed-top navbar--dark"><div class="navbar__inner"><div class="navbar__items"><div aria-label="Navigation bar toggle" class="navbar__toggle" role="button" tabindex="0"><svg xmlns="http://www.w3.org/2000/svg" width="30" height="30" viewBox="0 0 30 30" role="img" focusable="false"><title>Menu</title><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></div><a class="navbar__brand" href="/"><img class="navbar__logo" src="/img/header_logo.svg" alt="React Native"><strong class="navbar__title">React Native</strong></a><div class="navbar__item dropdown dropdown--hoverable dropdown--left"><a class="navbar__item navbar__link" href="/docs/getting-started">0.63</a><ul class="dropdown__menu"><li><a class="dropdown__link" href="/docs/next/_getting-started-macos-ios">Next</a></li><li><a aria-current="page" class="dropdown__link dropdown__link--active" href="/docs/_getting-started-macos-ios">0.63</a></li><li><a class="dropdown__link" href="/docs/0.62/_getting-started-macos-ios">0.62</a></li><li><a class="dropdown__link" href="/docs/0.61/_getting-started-macos-ios">0.61</a></li><li><a class="dropdown__link" href="/docs/0.60/_getting-started-macos-ios">0.60</a></li><li><a class="dropdown__link" href="/versions">All versions</a></li></ul></div></div><div class="navbar__items navbar__items--right"><a class="navbar__item navbar__link" href="/docs/getting-started">Docs</a><a class="navbar__item navbar__link" href="/docs/components-and-apis">Components</a><a class="navbar__item navbar__link" href="/docs/accessibilityinfo">API</a><a class="navbar__item navbar__link" href="/help">Community</a><a class="navbar__item navbar__link" href="/blog">Blog</a><a href="https://github.com/facebook/react-native" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link navbar-github-link" aria-label="GitHub repository"></a><div class="react-toggle react-toggle--disabled displayOnlyInLargeViewport_3lWe"><div class="react-toggle-track"><div class="react-toggle-track-check"><span class="toggle_gnXW">🌜</span></div><div class="react-toggle-track-x"><span class="toggle_gnXW">🌞</span></div></div><div class="react-toggle-thumb"></div><input type="checkbox" disabled="" aria-label="Dark mode toggle" class="react-toggle-screenreader-only"></div><button type="button" class="DocSearch DocSearch-Button" aria-label="Search"><svg width="20" height="20" class="DocSearch-Search-Icon" viewBox="0 0 20 20"><path d="M14.386 14.386l4.0877 4.0877-4.0877-4.0877c-2.9418 2.9419-7.7115 2.9419-10.6533 0-2.9419-2.9418-2.9419-7.7115 0-10.6533 2.9418-2.9419 7.7115-2.9419 10.6533 0 2.9419 2.9418 2.9419 7.7115 0 10.6533z" stroke="currentColor" fill="none" fill-rule="evenodd" stroke-linecap="round" stroke-linejoin="round"></path></svg><span class="DocSearch-Button-Placeholder">Search</span><span class="DocSearch-Button-Key">⌘</span><span class="DocSearch-Button-Key">K</span></button></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div><div class="navbar-sidebar"><div class="navbar-sidebar__brand"><a class="navbar__brand" href="/"><img class="navbar__logo" src="/img/header_logo.svg" alt="React Native"><strong class="navbar__title">React Native</strong></a></div><div class="navbar-sidebar__items"><div class="menu"><ul class="menu__list"><li class="menu__list-item"><a class="menu__link" href="/docs/getting-started">Docs</a></li><li class="menu__list-item"><a class="menu__link" href="/docs/components-and-apis">Components</a></li><li class="menu__list-item"><a class="menu__link" href="/docs/accessibilityinfo">API</a></li><li class="menu__list-item"><a class="menu__link" href="/help">Community</a></li><li class="menu__list-item"><a class="menu__link" href="/blog">Blog</a></li><li class="menu__list-item"><a role="button" class="menu__link menu__link--sublist">Versions</a><ul class="menu__list"><li class="menu__list-item"><a class="menu__link" href="/docs/next/_getting-started-macos-ios">Next</a></li><li class="menu__list-item"><a aria-current="page" class="menu__link menu__link--active" href="/docs/_getting-started-macos-ios">0.63</a></li><li class="menu__list-item"><a class="menu__link" href="/docs/0.62/_getting-started-macos-ios">0.62</a></li><li class="menu__list-item"><a class="menu__link" href="/docs/0.61/_getting-started-macos-ios">0.61</a></li><li class="menu__list-item"><a class="menu__link" href="/docs/0.60/_getting-started-macos-ios">0.60</a></li><li class="menu__list-item"><a class="menu__link" href="/versions">All versions</a></li></ul></li><li class="menu__list-item"><a href="https://github.com/facebook/react-native" target="_blank" rel="noopener noreferrer" class="menu__link navbar-github-link" aria-label="GitHub repository"></a></li></ul></div></div></div></nav><div class="main-wrapper"><div class="docPage_2UBv"><main class="docMainContainer_1rYT"><div class="container padding-vert--lg docItemWrapper_1Hme"><div class="row"><div class="col docItemCol_2AGf"><div class="docItemContainer_1tAC"><article><header><h1 class="docTitle_cWlf">_getting-started-macos-ios</h1></header><div class="markdown"><h2><a aria-hidden="true" tabindex="-1" class="anchor enhancedAnchor_3pqN" id="installing-dependencies"></a>Installing dependencies<a aria-hidden="true" tabindex="-1" class="hash-link" href="#installing-dependencies" title="Direct link to heading">#</a></h2><p>You will need Node, Watchman, the React Native command line interface, and Xcode.</p><p>While you can use any editor of your choice to develop your app, you will need to install Xcode in order to set up the necessary tooling to build your React Native app for iOS.</p><h3><a aria-hidden="true" tabindex="-1" class="anchor enhancedAnchor_3pqN" id="node--watchman"></a>Node & Watchman<a aria-hidden="true" tabindex="-1" class="hash-link" href="#node--watchman" title="Direct link to heading">#</a></h3><p>We recommend installing Node and Watchman using <a href="http://brew.sh/" target="_blank" rel="noopener noreferrer">Homebrew</a>. Run the following commands in a Terminal after installing Homebrew:</p><div class="mdxCodeBlock_xYIz"><div class="codeBlockContent_rlEb"><button tabindex="0" type="button" aria-label="Copy code to clipboard" class="copyButton_kOW4">Copy</button><div class="prism-code language-shell codeBlock_1AP7"><div class="codeBlockLines_1boI" style="color:#FFFFFF;background:#282C34"><div class="token-line" style="color:#FFFFFF;background:#282C34"><span class="token plain">brew </span><span class="token function" style="color:#79b6f2">install</span><span class="token plain"> node</span></div><div class="token-line" style="color:#FFFFFF;background:#282C34"><span class="token plain">brew </span><span class="token function" style="color:#79b6f2">install</span><span class="token plain"> watchman</span></div></div></div></div></div><p>If you have already installed Node on your system, make sure it is Node 10 or newer.</p><p><a href="https://facebook.github.io/watchman" target="_blank" rel="noopener noreferrer">Watchman</a> is a tool by Facebook for watching changes in the filesystem. It is highly recommended you install it for better performance.</p><h3><a aria-hidden="true" tabindex="-1" class="anchor enhancedAnchor_3pqN" id="xcode--cocoapods"></a>Xcode & CocoaPods<a aria-hidden="true" tabindex="-1" class="hash-link" href="#xcode--cocoapods" title="Direct link to heading">#</a></h3><p>The easiest way to install Xcode is via the <a href="https://itunes.apple.com/us/app/xcode/id497799835?mt=12" target="_blank" rel="noopener noreferrer">Mac App Store</a>. Installing Xcode will also install the iOS Simulator and all the necessary tools to build your iOS app.</p><p>If you have already installed Xcode on your system, make sure it is version 9.4 or newer.</p><h4><a aria-hidden="true" tabindex="-1" class="anchor enhancedAnchor_3pqN" id="command-line-tools"></a>Command Line Tools<a aria-hidden="true" tabindex="-1" class="hash-link" href="#command-line-tools" title="Direct link to heading">#</a></h4><p>You will also need to install the Xcode Command Line Tools. Open Xcode, then choose "Preferences..." from the Xcode menu. Go to the Locations panel and install the tools by selecting the most recent version in the Command Line Tools dropdown.</p><p><img alt="Xcode Command Line Tools" src="/assets/images/GettingStartedXcodeCommandLineTools-8259be8d3ab8575bec2b71988163c850.png"></p><h4><a aria-hidden="true" tabindex="-1" class="anchor enhancedAnchor_3pqN" id="installing-an-ios-simulator-in-xcode"></a>Installing an iOS Simulator in Xcode<a aria-hidden="true" tabindex="-1" class="hash-link" href="#installing-an-ios-simulator-in-xcode" title="Direct link to heading">#</a></h4><p>To install a simulator, open <strong>Xcode > Preferences...</strong> and select the <strong>Components</strong> tab. Select a simulator with the corresponding version of iOS you wish to use.</p><h4><a aria-hidden="true" tabindex="-1" class="anchor enhancedAnchor_3pqN" id="cocoapods"></a>CocoaPods<a aria-hidden="true" tabindex="-1" class="hash-link" href="#cocoapods" title="Direct link to heading">#</a></h4><p><a href="https://cocoapods.org/" target="_blank" rel="noopener noreferrer">CocoaPods</a> is built with Ruby and it will be installable with the default Ruby available on macOS. You can use a Ruby Version manager, however we recommend that you use the standard Ruby available on macOS unless you know what you're doing.</p><p>Using the default Ruby install will require you to use <code>sudo</code> when installing gems. (This is only an issue for the duration of the gem installation, though.)</p><div class="mdxCodeBlock_xYIz"><div class="codeBlockContent_rlEb"><button tabindex="0" type="button" aria-label="Copy code to clipboard" class="copyButton_kOW4">Copy</button><div class="prism-code language-shell codeBlock_1AP7"><div class="codeBlockLines_1boI" style="color:#FFFFFF;background:#282C34"><div class="token-line" style="color:#FFFFFF;background:#282C34"><span class="token function" style="color:#79b6f2">sudo</span><span class="token plain"> gem </span><span class="token function" style="color:#79b6f2">install</span><span class="token plain"> cocoapods</span></div></div></div></div></div><p>For more information, please visit <a href="https://guides.cocoapods.org/using/getting-started.html" target="_blank" rel="noopener noreferrer">CocoaPods Getting Started guide</a>.</p><h3><a aria-hidden="true" tabindex="-1" class="anchor enhancedAnchor_3pqN" id="react-native-command-line-interface"></a>React Native Command Line Interface<a aria-hidden="true" tabindex="-1" class="hash-link" href="#react-native-command-line-interface" title="Direct link to heading">#</a></h3><p>React Native has a built-in command line interface. Rather than install and manage a specific version of the CLI globally, we recommend you access the current version at runtime using <code>npx</code>, which ships with Node.js. With <code>npx react-native <command></code>, the current stable version of the CLI will be downloaded and executed at the time the command is run.</p><h2><a aria-hidden="true" tabindex="-1" class="anchor enhancedAnchor_3pqN" id="creating-a-new-application"></a>Creating a new application<a aria-hidden="true" tabindex="-1" class="hash-link" href="#creating-a-new-application" title="Direct link to heading">#</a></h2><blockquote><p>If you previously installed a global <code>react-native-cli</code> package, please remove it as it may cause unexpected issues.</p></blockquote><p>You can use React Native's built-in command line interface to generate a new project. Let's create a new React Native project called "AwesomeProject":</p><div class="mdxCodeBlock_xYIz"><div class="codeBlockContent_rlEb"><button tabindex="0" type="button" aria-label="Copy code to clipboard" class="copyButton_kOW4">Copy</button><div class="prism-code language-shell codeBlock_1AP7"><div class="codeBlockLines_1boI" style="color:#FFFFFF;background:#282C34"><div class="token-line" style="color:#FFFFFF;background:#282C34"><span class="token plain">npx react-native init AwesomeProject</span></div></div></div></div></div><p>This is not necessary if you are integrating React Native into an existing application, if you "ejected" from Expo, or if you're adding iOS support to an existing React Native project (see <a href="/docs/platform-specific-code">Platform Specific Code</a>). You can also use a third-party CLI to init your React Native app, such as <a href="https://github.com/infinitered/ignite" target="_blank" rel="noopener noreferrer">Ignite CLI</a>.</p><h3><a aria-hidden="true" tabindex="-1" class="anchor enhancedAnchor_3pqN" id="optional-using-a-specific-version-or-template"></a>[Optional] Using a specific version or template<a aria-hidden="true" tabindex="-1" class="hash-link" href="#optional-using-a-specific-version-or-template" title="Direct link to heading">#</a></h3><p>If you want to start a new project with a specific React Native version, you can use the <code>--version</code> argument:</p><div class="mdxCodeBlock_xYIz"><div class="codeBlockContent_rlEb"><button tabindex="0" type="button" aria-label="Copy code to clipboard" class="copyButton_kOW4">Copy</button><div class="prism-code language-shell codeBlock_1AP7"><div class="codeBlockLines_1boI" style="color:#FFFFFF;background:#282C34"><div class="token-line" style="color:#FFFFFF;background:#282C34"><span class="token plain">npx react-native init AwesomeProject --version X.XX.X</span></div></div></div></div></div><p>You can also start a project with a custom React Native template, like TypeScript, with <code>--template</code> argument:</p><div class="mdxCodeBlock_xYIz"><div class="codeBlockContent_rlEb"><button tabindex="0" type="button" aria-label="Copy code to clipboard" class="copyButton_kOW4">Copy</button><div class="prism-code language-shell codeBlock_1AP7"><div class="codeBlockLines_1boI" style="color:#FFFFFF;background:#282C34"><div class="token-line" style="color:#FFFFFF;background:#282C34"><span class="token plain">npx react-native init AwesomeTSProject --template react-native-template-typescript</span></div></div></div></div></div><blockquote><p><strong>Note</strong> If the above command is failing, you may have old version of <code>react-native</code> or <code>react-native-cli</code> installed globally on your pc. Try uninstalling the cli and run the cli using <code>npx</code>.</p></blockquote><h2><a aria-hidden="true" tabindex="-1" class="anchor enhancedAnchor_3pqN" id="running-your-react-native-application"></a>Running your React Native application<a aria-hidden="true" tabindex="-1" class="hash-link" href="#running-your-react-native-application" title="Direct link to heading">#</a></h2><h3><a aria-hidden="true" tabindex="-1" class="anchor enhancedAnchor_3pqN" id="step-1-start-metro"></a>Step 1: Start Metro<a aria-hidden="true" tabindex="-1" class="hash-link" href="#step-1-start-metro" title="Direct link to heading">#</a></h3><p>First, you will need to start Metro, the JavaScript bundler that ships with React Native. Metro "takes in an entry file and various options, and returns a single JavaScript file that includes all your code and its dependencies."—<a href="https://facebook.github.io/metro/docs/concepts" target="_blank" rel="noopener noreferrer">Metro Docs</a></p><p>To start Metro, run <code>npx react-native start</code> inside your React Native project folder:</p><div class="mdxCodeBlock_xYIz"><div class="codeBlockContent_rlEb"><button tabindex="0" type="button" aria-label="Copy code to clipboard" class="copyButton_kOW4">Copy</button><div class="prism-code language-shell codeBlock_1AP7"><div class="codeBlockLines_1boI" style="color:#FFFFFF;background:#282C34"><div class="token-line" style="color:#FFFFFF;background:#282C34"><span class="token plain">npx react-native start</span></div></div></div></div></div><p><code>react-native start</code> starts Metro Bundler.</p><blockquote><p>If you use the Yarn package manager, you can use <code>yarn</code> instead of <code>npx</code> when running React Native commands inside an existing project.</p></blockquote><blockquote><p>If you're familiar with web development, Metro is a lot like webpack—for React Native apps. Unlike Kotlin or Java, JavaScript isn't compiled—and neither is React Native. Bundling isn't the same as compiling, but it can help improve startup performance and translate some platform-specific JavaScript into more JavaScript.</p></blockquote><h3><a aria-hidden="true" tabindex="-1" class="anchor enhancedAnchor_3pqN" id="step-2-start-your-application"></a>Step 2: Start your application<a aria-hidden="true" tabindex="-1" class="hash-link" href="#step-2-start-your-application" title="Direct link to heading">#</a></h3><p>Let Metro Bundler run in its own terminal. Open a new terminal inside your React Native project folder. Run the following:</p><div class="mdxCodeBlock_xYIz"><div class="codeBlockContent_rlEb"><button tabindex="0" type="button" aria-label="Copy code to clipboard" class="copyButton_kOW4">Copy</button><div class="prism-code language-shell codeBlock_1AP7"><div class="codeBlockLines_1boI" style="color:#FFFFFF;background:#282C34"><div class="token-line" style="color:#FFFFFF;background:#282C34"><span class="token plain">npx react-native run-ios</span></div></div></div></div></div><p>You should see your new app running in the iOS Simulator shortly.</p><p><img alt="AwesomeProject on iOS" src="/assets/images/GettingStartediOSSuccess-e6dd7fc2baa303d1f30373d996a6e51d.png"></p><p><code>npx react-native run-ios</code> is one way to run your app. You can also run it directly from within Xcode.</p><blockquote><p>If you can't get this to work, see the <a href="/docs/troubleshooting#content">Troubleshooting</a> page.</p></blockquote><h3><a aria-hidden="true" tabindex="-1" class="anchor enhancedAnchor_3pqN" id="running-on-a-device"></a>Running on a device<a aria-hidden="true" tabindex="-1" class="hash-link" href="#running-on-a-device" title="Direct link to heading">#</a></h3><p>The above command will automatically run your app on the iOS Simulator by default. If you want to run the app on an actual physical iOS device, please follow the instructions <a href="/docs/running-on-device">here</a>.</p><h3><a aria-hidden="true" tabindex="-1" class="anchor enhancedAnchor_3pqN" id="modifying-your-app"></a>Modifying your app<a aria-hidden="true" tabindex="-1" class="hash-link" href="#modifying-your-app" title="Direct link to heading">#</a></h3><p>Now that you have successfully run the app, let's modify it.</p><ul><li>Open <code>App.js</code> in your text editor of choice and edit some lines.</li><li>Hit <code>⌘R</code> in your iOS Simulator to reload the app and see your changes!</li></ul><h3><a aria-hidden="true" tabindex="-1" class="anchor enhancedAnchor_3pqN" id="thats-it"></a>That's it!<a aria-hidden="true" tabindex="-1" class="hash-link" href="#thats-it" title="Direct link to heading">#</a></h3><p>Congratulations! You've successfully run and modified your first React Native app.</p><center><img src="/docs/assets/GettingStartedCongratulations.png" width="150"></center><h2><a aria-hidden="true" tabindex="-1" class="anchor enhancedAnchor_3pqN" id="now-what"></a>Now what?<a aria-hidden="true" tabindex="-1" class="hash-link" href="#now-what" title="Direct link to heading">#</a></h2><ul><li>If you want to add this new React Native code to an existing application, check out the <a href="/docs/integration-with-existing-apps">Integration guide</a>.</li></ul><p>If you're curious to learn more about React Native, check out the <a href="/docs/getting-started">Introduction to React Native</a>.</p></div></article><div class="docMetadata margin-vert--xl"><div class="row"><div class="col"><a href="https://github.com/facebook/react-native-website/blob/master/website/versioned_docs/version-0.63/_getting-started-macos-ios.md" target="_blank" rel="noreferrer noopener"><svg fill="currentColor" height="1.2em" width="1.2em" preserveAspectRatio="xMidYMid meet" viewBox="0 0 40 40" style="margin-right:0.3em;vertical-align:sub"><g><path d="m34.5 11.7l-3 3.1-6.3-6.3 3.1-3q0.5-0.5 1.2-0.5t1.1 0.5l3.9 3.9q0.5 0.4 0.5 1.1t-0.5 1.2z m-29.5 17.1l18.4-18.5 6.3 6.3-18.4 18.4h-6.3v-6.2z"></path></g></svg>Edit this page</a></div><div class="col text--right"><em><small class="docMetadata-updated">Last updated on <time datetime="2020-10-29T04:19:29.000Z" class="docLastUpdatedAt_1gIo">10/29/2020</time></small></em></div></div></div><div class="margin-vert--lg"><nav class="pagination-nav" aria-label="Blog list page navigation"><div class="pagination-nav__item"></div><div class="pagination-nav__item pagination-nav__item--next"></div></nav></div></div></div><div class="col col--3"><div class="tableOfContents_3iuQ"><ul class="table-of-contents table-of-contents__left-border"><li><a href="#installing-dependencies" class="table-of-contents__link">Installing dependencies</a><ul><li><a href="#node--watchman" class="table-of-contents__link">Node & Watchman</a></li><li><a href="#xcode--cocoapods" class="table-of-contents__link">Xcode & CocoaPods</a></li><li><a href="#react-native-command-line-interface" class="table-of-contents__link">React Native Command Line Interface</a></li></ul></li><li><a href="#creating-a-new-application" class="table-of-contents__link">Creating a new application</a><ul><li><a href="#optional-using-a-specific-version-or-template" class="table-of-contents__link">Optional Using a specific version or template</a></li></ul></li><li><a href="#running-your-react-native-application" class="table-of-contents__link">Running your React Native application</a><ul><li><a href="#step-1-start-metro" class="table-of-contents__link">Step 1: Start Metro</a></li><li><a href="#step-2-start-your-application" class="table-of-contents__link">Step 2: Start your application</a></li><li><a href="#running-on-a-device" class="table-of-contents__link">Running on a device</a></li><li><a href="#modifying-your-app" class="table-of-contents__link">Modifying your app</a></li><li><a href="#thats-it" class="table-of-contents__link">That's it!</a></li></ul></li><li><a href="#now-what" class="table-of-contents__link">Now what?</a></li></ul></div></div></div></div></main></div></div><footer class="footer footer--dark"><div class="container"><div class="row footer__links"><div class="col footer__col"><h4 class="footer__title">Docs</h4><ul class="footer__items"><li class="footer__item"><a class="footer__link-item" href="/docs/getting-started">Getting Started</a></li><li class="footer__item"><a class="footer__link-item" href="/docs/tutorial">Tutorial</a></li><li class="footer__item"><a class="footer__link-item" href="/docs/components-and-apis">Components and APIs</a></li><li class="footer__item"><a class="footer__link-item" href="/docs/more-resources">More Resources</a></li></ul></div><div class="col footer__col"><h4 class="footer__title">Community</h4><ul class="footer__items"><li class="footer__item"><a class="footer__link-item" href="/help">The React Native Community</a></li><li class="footer__item"><a class="footer__link-item" href="/showcase">Who's using React Native?</a></li><li class="footer__item"><a href="https://stackoverflow.com/questions/tagged/react-native" target="_blank" rel="noopener noreferrer" class="footer__link-item">Ask Questions on Stack Overflow</a></li><li class="footer__item"><a href="https://github.com/facebook/react-native/blob/master/CONTRIBUTING.md" target="_blank" rel="noopener noreferrer" class="footer__link-item">Contributor Guide</a></li><li class="footer__item"><a href="https://dev.to/t/reactnative" target="_blank" rel="noopener noreferrer" class="footer__link-item">DEV Community</a></li></ul></div><div class="col footer__col"><h4 class="footer__title">Find us</h4><ul class="footer__items"><li class="footer__item"><a class="footer__link-item" href="/blog">Blog</a></li><li class="footer__item"><a href="https://twitter.com/reactnative" target="_blank" rel="noopener noreferrer" class="footer__link-item">Twitter</a></li><li class="footer__item"><a href="https://github.com/facebook/react-native" target="_blank" rel="noopener noreferrer" class="footer__link-item">GitHub</a></li></ul></div><div class="col footer__col"><h4 class="footer__title">More</h4><ul class="footer__items"><li class="footer__item"><a href="https://reactjs.org/" target="_blank" rel="noopener noreferrer" class="footer__link-item">React</a></li><li class="footer__item"><a href="https://opensource.facebook.com/legal/privacy" target="_blank" rel="noopener noreferrer" class="footer__link-item">Privacy Policy</a></li><li class="footer__item"><a href="https://opensource.facebook.com/legal/terms" target="_blank" rel="noopener noreferrer" class="footer__link-item">Terms of Service</a></li></ul></div></div><div class="text--center"><div class="margin-bottom--sm"><a href="https://opensource.facebook.com" target="_blank" rel="noopener noreferrer" class="footerLogoLink_19Ac"><img class="footer__logo" alt="Facebook Open Source Logo" src="/img/oss_logo.png"></a></div><div>Copyright © 2021 Facebook, Inc.</div></div></div></footer></div>
|
|
<script src="/styles.07d522c6.js"></script>
|
|
<script src="/runtime~main.7f243cb9.js"></script>
|
|
<script src="/main.5e05a427.js"></script>
|
|
<script src="/1.ba9ce8bd.js"></script>
|
|
<script src="/2.58cb5d3d.js"></script>
|
|
<script src="/1f391b9e.a824c215.js"></script>
|
|
<script src="/943.8b024446.js"></script>
|
|
<script src="/ee5b3385.b4fff665.js"></script>
|
|
<script src="/17896441.0c201679.js"></script>
|
|
<script src="/f612f9dd.9478b041.js"></script>
|
|
<script src="/f88ba1af.66e13c4c.js"></script>
|
|
</body>
|
|
</html> |