mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
update website
This commit is contained in:
+2
-2
@@ -29,8 +29,8 @@ on it to trigger navigation:</p><ul><li><code>getCurrentRoutes()</code> - return
|
||||
array of routes</li><li><code>popToRoute(route)</code> - Pop to a particular scene, as specified by its
|
||||
route. All scenes after it will be unmounted</li><li><code>popToTop()</code> - Pop to the first scene in the stack, unmounting every
|
||||
other scene</li></ul></div><h3><a class="anchor" name="props"></a><a class="edit-github" href="https://github.com/facebook/react-native/blob/master/Libraries/CustomComponents/Navigator/Navigator.js">Edit on GitHub</a>Props <a class="hash-link" href="#props">#</a></h3><div class="props"><div class="prop"><h4 class="propTitle"><a class="anchor" name="configurescene"></a>configureScene <span class="propType">function</span> <a class="hash-link" href="#configurescene">#</a></h4><div><p>Optional function that allows configuration about scene animations and
|
||||
gestures. Will be invoked with the route and should return a scene
|
||||
configuration object</p><div class="prism language-javascript"><span class="token punctuation">(</span>route<span class="token punctuation">)</span> <span class="token operator">=</span><span class="token operator">></span> Navigator<span class="token punctuation">.</span>SceneConfigs<span class="token punctuation">.</span>FloatFromRight</div></div></div><div class="prop"><h4 class="propTitle"><a class="anchor" name="initialroute"></a>initialRoute <span class="propType">object</span> <a class="hash-link" href="#initialroute">#</a></h4><div><p>Specify a route to start on. A route is an object that the navigator
|
||||
gestures. Will be invoked with the route and the routeStack and should
|
||||
return a scene configuration object</p><div class="prism language-javascript"><span class="token punctuation">(</span>route<span class="token punctuation">,</span> routeStack<span class="token punctuation">)</span> <span class="token operator">=</span><span class="token operator">></span> Navigator<span class="token punctuation">.</span>SceneConfigs<span class="token punctuation">.</span>FloatFromRight</div></div></div><div class="prop"><h4 class="propTitle"><a class="anchor" name="initialroute"></a>initialRoute <span class="propType">object</span> <a class="hash-link" href="#initialroute">#</a></h4><div><p>Specify a route to start on. A route is an object that the navigator
|
||||
will use to identify each scene to render. <code>initialRoute</code> must be
|
||||
a route in the <code>initialRouteStack</code> if both props are provided. The
|
||||
<code>initialRoute</code> will default to the last item in the <code>initialRouteStack</code>.</p></div></div><div class="prop"><h4 class="propTitle"><a class="anchor" name="initialroutestack"></a>initialRouteStack <span class="propType">[object]</span> <a class="hash-link" href="#initialroutestack">#</a></h4><div><p>Provide a set of routes to initially mount. Required if no initialRoute
|
||||
|
||||
Reference in New Issue
Block a user