{"action":"created","issue":{"url":"https://api.github.com/repos/react-native-community/react-native-tab-view/issues/33","repository_url":"https://api.github.com/repos/react-native-community/react-native-tab-view","labels_url":"https://api.github.com/repos/react-native-community/react-native-tab-view/issues/33/labels{/name}","comments_url":"https://api.github.com/repos/react-native-community/react-native-tab-view/issues/33/comments","events_url":"https://api.github.com/repos/react-native-community/react-native-tab-view/issues/33/events","html_url":"https://github.com/react-native-community/react-native-tab-view/pull/33","id":180513866,"number":33,"title":"Only update layout state if it changed","user":{"login":"ryankask","id":81891,"avatar_url":"https://avatars.githubusercontent.com/u/81891?v=3","gravatar_id":"","url":"https://api.github.com/users/ryankask","html_url":"https://github.com/ryankask","followers_url":"https://api.github.com/users/ryankask/followers","following_url":"https://api.github.com/users/ryankask/following{/other_user}","gists_url":"https://api.github.com/users/ryankask/gists{/gist_id}","starred_url":"https://api.github.com/users/ryankask/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ryankask/subscriptions","organizations_url":"https://api.github.com/users/ryankask/orgs","repos_url":"https://api.github.com/users/ryankask/repos","events_url":"https://api.github.com/users/ryankask/events{/privacy}","received_events_url":"https://api.github.com/users/ryankask/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2016-10-02T14:06:24Z","updated_at":"2016-10-02T17:43:29Z","closed_at":"2016-10-02T16:33:18Z","pull_request":{"url":"https://api.github.com/repos/react-native-community/react-native-tab-view/pulls/33","html_url":"https://github.com/react-native-community/react-native-tab-view/pull/33","diff_url":"https://github.com/react-native-community/react-native-tab-view/pull/33.diff","patch_url":"https://github.com/react-native-community/react-native-tab-view/pull/33.patch"},"body":"I just upgraded my app to React Native 0.34 and I have a react-native-maps `MapView` in one of my tabs.\r\n\r\nI noticed that the map was continuously rendering and pinned it down to the `TabViewTransitioner#_handleLayout()`. It calls `setState()` even if the width and height haven't changed so this patch stops that.\r\n\r\nThere was actually a recent RN commit for `NavigationTransitioner` that does the same thing here: https://github.com/facebook/react-native/commit/dadfe40f55f0fc21e833e36ac2ad67ec4160af25"},"comment":{"url":"https://api.github.com/repos/react-native-community/react-native-tab-view/issues/comments/250984087","html_url":"https://github.com/react-native-community/react-native-tab-view/pull/33#issuecomment-250984087","issue_url":"https://api.github.com/repos/react-native-community/react-native-tab-view/issues/33","id":250984087,"user":{"login":"ryankask","id":81891,"avatar_url":"https://avatars.githubusercontent.com/u/81891?v=3","gravatar_id":"","url":"https://api.github.com/users/ryankask","html_url":"https://github.com/ryankask","followers_url":"https://api.github.com/users/ryankask/followers","following_url":"https://api.github.com/users/ryankask/following{/other_user}","gists_url":"https://api.github.com/users/ryankask/gists{/gist_id}","starred_url":"https://api.github.com/users/ryankask/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ryankask/subscriptions","organizations_url":"https://api.github.com/users/ryankask/orgs","repos_url":"https://api.github.com/users/ryankask/repos","events_url":"https://api.github.com/users/ryankask/events{/privacy}","received_events_url":"https://api.github.com/users/ryankask/received_events","type":"User","site_admin":false},"created_at":"2016-10-02T17:43:29Z","updated_at":"2016-10-02T17:43:29Z","body":"I should have mentioned this was only happening on Android and only when the `MapView` had `MapView.Marker` children.\r\n\r\nIt seems like when the native markers are added they trigger a layout, which causes them to be re-rendered leading to another layout and a cycle.\r\n\r\nTo be honest I'm not really sure..."}}
{"actor":{"display_login":"ryankask"}}