{"action":"created","issue":{"url":"https://api.github.com/repos/react-community/react-navigation/issues/620","repository_url":"https://api.github.com/repos/react-community/react-navigation","labels_url":"https://api.github.com/repos/react-community/react-navigation/issues/620/labels{/name}","comments_url":"https://api.github.com/repos/react-community/react-navigation/issues/620/comments","events_url":"https://api.github.com/repos/react-community/react-navigation/issues/620/events","html_url":"https://github.com/react-community/react-navigation/issues/620","id":212891439,"number":620,"title":"Initial route after user logged in?","user":{"login":"AlpZero","id":17249907,"avatar_url":"https://avatars1.githubusercontent.com/u/17249907?v=4","gravatar_id":"","url":"https://api.github.com/users/AlpZero","html_url":"https://github.com/AlpZero","followers_url":"https://api.github.com/users/AlpZero/followers","following_url":"https://api.github.com/users/AlpZero/following{/other_user}","gists_url":"https://api.github.com/users/AlpZero/gists{/gist_id}","starred_url":"https://api.github.com/users/AlpZero/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AlpZero/subscriptions","organizations_url":"https://api.github.com/users/AlpZero/orgs","repos_url":"https://api.github.com/users/AlpZero/repos","events_url":"https://api.github.com/users/AlpZero/events{/privacy}","received_events_url":"https://api.github.com/users/AlpZero/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":15,"created_at":"2017-03-08T23:42:39Z","updated_at":"2017-11-03T20:49:23Z","closed_at":"2017-03-11T02:28:08Z","author_association":"NONE","body":"In Navigator, i change initial route passing a function to the prop definition, ex: \r\n`<Navigator initialRoute={ this.initialRoute() } />`\r\nHow can i do the same in react-navigation?\r\n\r\n**Edit** \r\n\r\nWith the navigator, i connect the state and the navigator with connect(state)(navigator), but if i do the same with react-navigation, it obviously doesn't works because that is not the correct way to do that.\r\nOther way to do that is using the store.getState() in a function in initialRouteName, but it look's weird for me, i want to use react-redux, but i don't know how.\r\nIs there a way to do this?\r\n"},"comment":{"url":"https://api.github.com/repos/react-community/react-navigation/issues/comments/341823266","html_url":"https://github.com/react-community/react-navigation/issues/620#issuecomment-341823266","issue_url":"https://api.github.com/repos/react-community/react-navigation/issues/620","id":341823266,"user":{"login":"kelset","id":16104054,"avatar_url":"https://avatars3.githubusercontent.com/u/16104054?v=4","gravatar_id":"","url":"https://api.github.com/users/kelset","html_url":"https://github.com/kelset","followers_url":"https://api.github.com/users/kelset/followers","following_url":"https://api.github.com/users/kelset/following{/other_user}","gists_url":"https://api.github.com/users/kelset/gists{/gist_id}","starred_url":"https://api.github.com/users/kelset/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kelset/subscriptions","organizations_url":"https://api.github.com/users/kelset/orgs","repos_url":"https://api.github.com/users/kelset/repos","events_url":"https://api.github.com/users/kelset/events{/privacy}","received_events_url":"https://api.github.com/users/kelset/received_events","type":"User","site_admin":false},"created_at":"2017-11-03T20:49:23Z","updated_at":"2017-11-03T20:49:23Z","author_association":"COLLABORATOR","body":"I agree with @AlpZero , that's actually the approach I use too in my prod app.\r\n\r\nIf you want another approach, [this article](https://shift.infinite.red/react-navigation-drawer-tutorial-part-2-9c382217ac6b) we link in the README also provide a way to do it.\r\n\r\nBtw if you feel that the docs are not in-depth enough, feel free to submit a PR to them, we'll review it asap :) PRs to Docs are always welcome :)"}}
{"actor":{"display_login":"kelset"}}