aksonov / react-native-router-flux

The first declarative React Native router
MIT License
8.99k stars 2.11k forks source link

Link several positions on the same page using pathPrefix #3818

Open mitchiemt11 opened 2 years ago

mitchiemt11 commented 2 years ago

Version

Tell us which versions you are using:

Expected behaviour

To open a certain tab on a page on the same scene given the specific path in android pathPrefix

Actual behaviour

The app only opens a name page without going to a specific position on that screen

Steps to reproduce

For non-obvious bugs, please fork this component, modify Example project to reproduce your issue and include link here.

  1. Include .* in scene path but it did not work

Reproducible Demo

Please provide a minimized reproducible demonstration of the problem you're reporting.

Issues that come with minimal repro's are resolved much more quickly than issues where a maintainer has to reproduce themselves. I have my router.js defined like this

**import React from 'react'; import {ActionConst, Router, Scene} from 'react-native-router-flux'; import {trackScreen} from '../common/analytics' import homePage from '../pages/homePage/homePage'; import landingPage from '../pages/landingPage/landingPage';

const RouterComponent = ({initialRouteName}) => { const routeName = initialRouteName ? initialRouteName : 'home'; return ( <Router uriPrefix={'app.test.com'} initialRouteName={routeName} onStateChange={trackScreen}

/> I have the home page with 3 tabs in that page name Home, Family, Privacy.I would like to navigate using deep link to https://app.test.com/family in home page. Passing a path prop in scene does not work. Here is my .xml file to handle the deep link: ` ` Any help please!