{"action":"closed","number":6217,"pull_request":{"url":"https://api.github.com/repos/ReactTraining/react-router/pulls/6217","id":196081215,"node_id":"MDExOlB1bGxSZXF1ZXN0MTk2MDgxMjE1","html_url":"https://github.com/ReactTraining/react-router/pull/6217","diff_url":"https://github.com/ReactTraining/react-router/pull/6217.diff","patch_url":"https://github.com/ReactTraining/react-router/pull/6217.patch","issue_url":"https://api.github.com/repos/ReactTraining/react-router/issues/6217","number":6217,"state":"closed","locked":false,"title":"Added support for render method in react-router-config","user":{"login":"benatespina","id":3951376,"node_id":"MDQ6VXNlcjM5NTEzNzY=","avatar_url":"https://avatars0.githubusercontent.com/u/3951376?v=4","gravatar_id":"","url":"https://api.github.com/users/benatespina","html_url":"https://github.com/benatespina","followers_url":"https://api.github.com/users/benatespina/followers","following_url":"https://api.github.com/users/benatespina/following{/other_user}","gists_url":"https://api.github.com/users/benatespina/gists{/gist_id}","starred_url":"https://api.github.com/users/benatespina/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/benatespina/subscriptions","organizations_url":"https://api.github.com/users/benatespina/orgs","repos_url":"https://api.github.com/users/benatespina/repos","events_url":"https://api.github.com/users/benatespina/events{/privacy}","received_events_url":"https://api.github.com/users/benatespina/received_events","type":"User","site_admin":false},"body":"This PR allows to use render as valid callback in the `react-router-config` configuration tree.\r\n\r\nIt tries to resolve the #4962 issue and it's implemented based on this idea:\r\nhttps://github.com/ReactTraining/react-router/issues/4962#issuecomment-376567551\r\n\r\nFor example:\r\n```\r\n{\r\n    {\r\n        path: \"/restricted-area\",\r\n        render: (props) => isUserLoggedIn() ? <RestrictedArea/> : <Redirect to=\"/login\"/>\r\n    },\r\n    {\r\n        path: \"/login\",\r\n        component: Login\r\n    }\r\n}\r\n```","created_at":"2018-06-20T09:50:04Z","updated_at":"2018-06-22T13:56:44Z","closed_at":"2018-06-22T13:56:44Z","merged_at":"2018-06-22T13:56:44Z","merge_commit_sha":"d28d46dce08a5756a085f7e5eebb5169ea59e40b","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/ReactTraining/react-router/pulls/6217/commits","review_comments_url":"https://api.github.com/repos/ReactTraining/react-router/pulls/6217/comments","review_comment_url":"https://api.github.com/repos/ReactTraining/react-router/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ReactTraining/react-router/issues/6217/comments","statuses_url":"https://api.github.com/repos/ReactTraining/react-router/statuses/e709b299f912d9cdd25fd0f5c6d8f57cb0e180ff","head":{"label":"benatespina:feature/route-render","ref":"feature/route-render","sha":"e709b299f912d9cdd25fd0f5c6d8f57cb0e180ff","user":{"login":"benatespina","id":3951376,"node_id":"MDQ6VXNlcjM5NTEzNzY=","avatar_url":"https://avatars0.githubusercontent.com/u/3951376?v=4","gravatar_id":"","url":"https://api.github.com/users/benatespina","html_url":"https://github.com/benatespina","followers_url":"https://api.github.com/users/benatespina/followers","following_url":"https://api.github.com/users/benatespina/following{/other_user}","gists_url":"https://api.github.com/users/benatespina/gists{/gist_id}","starred_url":"https://api.github.com/users/benatespina/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/benatespina/subscriptions","organizations_url":"https://api.github.com/users/benatespina/orgs","repos_url":"https://api.github.com/users/benatespina/repos","events_url":"https://api.github.com/users/benatespina/events{/privacy}","received_events_url":"https://api.github.com/users/benatespina/received_events","type":"User","site_admin":false},"repo":{"id":138004182,"node_id":"MDEwOlJlcG9zaXRvcnkxMzgwMDQxODI=","name":"react-router","full_name":"benatespina/react-router","owner":{"login":"benatespina","id":3951376,"node_id":"MDQ6VXNlcjM5NTEzNzY=","avatar_url":"https://avatars0.githubusercontent.com/u/3951376?v=4","gravatar_id":"","url":"https://api.github.com/users/benatespina","html_url":"https://github.com/benatespina","followers_url":"https://api.github.com/users/benatespina/followers","following_url":"https://api.github.com/users/benatespina/following{/other_user}","gists_url":"https://api.github.com/users/benatespina/gists{/gist_id}","starred_url":"https://api.github.com/users/benatespina/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/benatespina/subscriptions","organizations_url":"https://api.github.com/users/benatespina/orgs","repos_url":"https://api.github.com/users/benatespina/repos","events_url":"https://api.github.com/users/benatespina/events{/privacy}","received_events_url":"https://api.github.com/users/benatespina/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/benatespina/react-router","description":"Declarative routing for React","fork":true,"url":"https://api.github.com/repos/benatespina/react-router","forks_url":"https://api.github.com/repos/benatespina/react-router/forks","keys_url":"https://api.github.com/repos/benatespina/react-router/keys{/key_id}","collaborators_url":"https://api.github.com/repos/benatespina/react-router/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/benatespina/react-router/teams","hooks_url":"https://api.github.com/repos/benatespina/react-router/hooks","issue_events_url":"https://api.github.com/repos/benatespina/react-router/issues/events{/number}","events_url":"https://api.github.com/repos/benatespina/react-router/events","assignees_url":"https://api.github.com/repos/benatespina/react-router/assignees{/user}","branches_url":"https://api.github.com/repos/benatespina/react-router/branches{/branch}","tags_url":"https://api.github.com/repos/benatespina/react-router/tags","blobs_url":"https://api.github.com/repos/benatespina/react-router/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/benatespina/react-router/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/benatespina/react-router/git/refs{/sha}","trees_url":"https://api.github.com/repos/benatespina/react-router/git/trees{/sha}","statuses_url":"https://api.github.com/repos/benatespina/react-router/statuses/{sha}","languages_url":"https://api.github.com/repos/benatespina/react-router/languages","stargazers_url":"https://api.github.com/repos/benatespina/react-router/stargazers","contributors_url":"https://api.github.com/repos/benatespina/react-router/contributors","subscribers_url":"https://api.github.com/repos/benatespina/react-router/subscribers","subscription_url":"https://api.github.com/repos/benatespina/react-router/subscription","commits_url":"https://api.github.com/repos/benatespina/react-router/commits{/sha}","git_commits_url":"https://api.github.com/repos/benatespina/react-router/git/commits{/sha}","comments_url":"https://api.github.com/repos/benatespina/react-router/comments{/number}","issue_comment_url":"https://api.github.com/repos/benatespina/react-router/issues/comments{/number}","contents_url":"https://api.github.com/repos/benatespina/react-router/contents/{+path}","compare_url":"https://api.github.com/repos/benatespina/react-router/compare/{base}...{head}","merges_url":"https://api.github.com/repos/benatespina/react-router/merges","archive_url":"https://api.github.com/repos/benatespina/react-router/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/benatespina/react-router/downloads","issues_url":"https://api.github.com/repos/benatespina/react-router/issues{/number}","pulls_url":"https://api.github.com/repos/benatespina/react-router/pulls{/number}","milestones_url":"https://api.github.com/repos/benatespina/react-router/milestones{/number}","notifications_url":"https://api.github.com/repos/benatespina/react-router/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/benatespina/react-router/labels{/name}","releases_url":"https://api.github.com/repos/benatespina/react-router/releases{/id}","deployments_url":"https://api.github.com/repos/benatespina/react-router/deployments","created_at":"2018-06-20T08:39:42Z","updated_at":"2018-06-20T08:39:48Z","pushed_at":"2018-06-22T07:28:10Z","git_url":"git://github.com/benatespina/react-router.git","ssh_url":"git@github.com:benatespina/react-router.git","clone_url":"https://github.com/benatespina/react-router.git","svn_url":"https://github.com/benatespina/react-router","homepage":"https://reacttraining.com/react-router/","size":8883,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"ReactTraining:master","ref":"master","sha":"f184bd897f3b9ad3a32eaa8060539ad7f4c233b4","user":{"login":"ReactTraining","id":11823761,"node_id":"MDEyOk9yZ2FuaXphdGlvbjExODIzNzYx","avatar_url":"https://avatars1.githubusercontent.com/u/11823761?v=4","gravatar_id":"","url":"https://api.github.com/users/ReactTraining","html_url":"https://github.com/ReactTraining","followers_url":"https://api.github.com/users/ReactTraining/followers","following_url":"https://api.github.com/users/ReactTraining/following{/other_user}","gists_url":"https://api.github.com/users/ReactTraining/gists{/gist_id}","starred_url":"https://api.github.com/users/ReactTraining/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ReactTraining/subscriptions","organizations_url":"https://api.github.com/users/ReactTraining/orgs","repos_url":"https://api.github.com/users/ReactTraining/repos","events_url":"https://api.github.com/users/ReactTraining/events{/privacy}","received_events_url":"https://api.github.com/users/ReactTraining/received_events","type":"Organization","site_admin":false},"repo":{"id":19872456,"node_id":"MDEwOlJlcG9zaXRvcnkxOTg3MjQ1Ng==","name":"react-router","full_name":"ReactTraining/react-router","owner":{"login":"ReactTraining","id":11823761,"node_id":"MDEyOk9yZ2FuaXphdGlvbjExODIzNzYx","avatar_url":"https://avatars1.githubusercontent.com/u/11823761?v=4","gravatar_id":"","url":"https://api.github.com/users/ReactTraining","html_url":"https://github.com/ReactTraining","followers_url":"https://api.github.com/users/ReactTraining/followers","following_url":"https://api.github.com/users/ReactTraining/following{/other_user}","gists_url":"https://api.github.com/users/ReactTraining/gists{/gist_id}","starred_url":"https://api.github.com/users/ReactTraining/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ReactTraining/subscriptions","organizations_url":"https://api.github.com/users/ReactTraining/orgs","repos_url":"https://api.github.com/users/ReactTraining/repos","events_url":"https://api.github.com/users/ReactTraining/events{/privacy}","received_events_url":"https://api.github.com/users/ReactTraining/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ReactTraining/react-router","description":"Declarative routing for React","fork":false,"url":"https://api.github.com/repos/ReactTraining/react-router","forks_url":"https://api.github.com/repos/ReactTraining/react-router/forks","keys_url":"https://api.github.com/repos/ReactTraining/react-router/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ReactTraining/react-router/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ReactTraining/react-router/teams","hooks_url":"https://api.github.com/repos/ReactTraining/react-router/hooks","issue_events_url":"https://api.github.com/repos/ReactTraining/react-router/issues/events{/number}","events_url":"https://api.github.com/repos/ReactTraining/react-router/events","assignees_url":"https://api.github.com/repos/ReactTraining/react-router/assignees{/user}","branches_url":"https://api.github.com/repos/ReactTraining/react-router/branches{/branch}","tags_url":"https://api.github.com/repos/ReactTraining/react-router/tags","blobs_url":"https://api.github.com/repos/ReactTraining/react-router/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ReactTraining/react-router/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ReactTraining/react-router/git/refs{/sha}","trees_url":"https://api.github.com/repos/ReactTraining/react-router/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ReactTraining/react-router/statuses/{sha}","languages_url":"https://api.github.com/repos/ReactTraining/react-router/languages","stargazers_url":"https://api.github.com/repos/ReactTraining/react-router/stargazers","contributors_url":"https://api.github.com/repos/ReactTraining/react-router/contributors","subscribers_url":"https://api.github.com/repos/ReactTraining/react-router/subscribers","subscription_url":"https://api.github.com/repos/ReactTraining/react-router/subscription","commits_url":"https://api.github.com/repos/ReactTraining/react-router/commits{/sha}","git_commits_url":"https://api.github.com/repos/ReactTraining/react-router/git/commits{/sha}","comments_url":"https://api.github.com/repos/ReactTraining/react-router/comments{/number}","issue_comment_url":"https://api.github.com/repos/ReactTraining/react-router/issues/comments{/number}","contents_url":"https://api.github.com/repos/ReactTraining/react-router/contents/{+path}","compare_url":"https://api.github.com/repos/ReactTraining/react-router/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ReactTraining/react-router/merges","archive_url":"https://api.github.com/repos/ReactTraining/react-router/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ReactTraining/react-router/downloads","issues_url":"https://api.github.com/repos/ReactTraining/react-router/issues{/number}","pulls_url":"https://api.github.com/repos/ReactTraining/react-router/pulls{/number}","milestones_url":"https://api.github.com/repos/ReactTraining/react-router/milestones{/number}","notifications_url":"https://api.github.com/repos/ReactTraining/react-router/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ReactTraining/react-router/labels{/name}","releases_url":"https://api.github.com/repos/ReactTraining/react-router/releases{/id}","deployments_url":"https://api.github.com/repos/ReactTraining/react-router/deployments","created_at":"2014-05-16T22:22:51Z","updated_at":"2018-06-22T13:56:15Z","pushed_at":"2018-06-22T13:56:44Z","git_url":"git://github.com/ReactTraining/react-router.git","ssh_url":"git@github.com:ReactTraining/react-router.git","clone_url":"https://github.com/ReactTraining/react-router.git","svn_url":"https://github.com/ReactTraining/react-router","homepage":"https://reacttraining.com/react-router/","size":8880,"stargazers_count":31035,"watchers_count":31035,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":6602,"mirror_url":null,"archived":false,"open_issues_count":47,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":6602,"open_issues":47,"watchers":31035,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ReactTraining/react-router/pulls/6217"},"html":{"href":"https://github.com/ReactTraining/react-router/pull/6217"},"issue":{"href":"https://api.github.com/repos/ReactTraining/react-router/issues/6217"},"comments":{"href":"https://api.github.com/repos/ReactTraining/react-router/issues/6217/comments"},"review_comments":{"href":"https://api.github.com/repos/ReactTraining/react-router/pulls/6217/comments"},"review_comment":{"href":"https://api.github.com/repos/ReactTraining/react-router/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ReactTraining/react-router/pulls/6217/commits"},"statuses":{"href":"https://api.github.com/repos/ReactTraining/react-router/statuses/e709b299f912d9cdd25fd0f5c6d8f57cb0e180ff"}},"author_association":"NONE","merged":true,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":{"login":"timdorr","id":17882,"node_id":"MDQ6VXNlcjE3ODgy","avatar_url":"https://avatars2.githubusercontent.com/u/17882?v=4","gravatar_id":"","url":"https://api.github.com/users/timdorr","html_url":"https://github.com/timdorr","followers_url":"https://api.github.com/users/timdorr/followers","following_url":"https://api.github.com/users/timdorr/following{/other_user}","gists_url":"https://api.github.com/users/timdorr/gists{/gist_id}","starred_url":"https://api.github.com/users/timdorr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/timdorr/subscriptions","organizations_url":"https://api.github.com/users/timdorr/orgs","repos_url":"https://api.github.com/users/timdorr/repos","events_url":"https://api.github.com/users/timdorr/events{/privacy}","received_events_url":"https://api.github.com/users/timdorr/received_events","type":"User","site_admin":false},"comments":3,"review_comments":0,"maintainer_can_modify":false,"commits":2,"additions":24,"deletions":3,"changed_files":2}}
{"actor":{"display_login":"timdorr"}}