{"action":"created","issue":{"url":"https://api.github.com/repos/leecade/react-native-swiper/issues/538","repository_url":"https://api.github.com/repos/leecade/react-native-swiper","labels_url":"https://api.github.com/repos/leecade/react-native-swiper/issues/538/labels{/name}","comments_url":"https://api.github.com/repos/leecade/react-native-swiper/issues/538/comments","events_url":"https://api.github.com/repos/leecade/react-native-swiper/issues/538/events","html_url":"https://github.com/leecade/react-native-swiper/issues/538","id":252801200,"number":538,"title":"[Android] Problem updating swiper views","user":{"login":"ScrimpyCat","id":3411736,"avatar_url":"https://avatars1.githubusercontent.com/u/3411736?v=4","gravatar_id":"","url":"https://api.github.com/users/ScrimpyCat","html_url":"https://github.com/ScrimpyCat","followers_url":"https://api.github.com/users/ScrimpyCat/followers","following_url":"https://api.github.com/users/ScrimpyCat/following{/other_user}","gists_url":"https://api.github.com/users/ScrimpyCat/gists{/gist_id}","starred_url":"https://api.github.com/users/ScrimpyCat/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ScrimpyCat/subscriptions","organizations_url":"https://api.github.com/users/ScrimpyCat/orgs","repos_url":"https://api.github.com/users/ScrimpyCat/repos","events_url":"https://api.github.com/users/ScrimpyCat/events{/privacy}","received_events_url":"https://api.github.com/users/ScrimpyCat/received_events","type":"User","site_admin":false},"labels":[{"id":201906558,"url":"https://api.github.com/repos/leecade/react-native-swiper/labels/bug","name":"bug","color":"fc2929","default":true},{"id":667441261,"url":"https://api.github.com/repos/leecade/react-native-swiper/labels/Need%20answer%20from%20author","name":"Need answer from author","color":"5319e7","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2017-08-25T05:20:51Z","updated_at":"2017-09-22T09:02:46Z","closed_at":null,"author_association":"NONE","body":"I have a need for a swiper with dynamic items, some may be added or removed at runtime. This works fine on iOS, but has problems on Android.\r\n\r\n### Which OS ?\r\nAndroid\r\n\r\n### Version\r\nWhich versions are you using:\r\n\r\n- react-native-swiper v? 1.5.4\r\n- react-native v0.?.? 0.46.4\r\n\r\n### Expected behaviour\r\n\r\nHaving a swiper with 4 items and adding some new items (say 2 more for a total of 6) should allow for 6 items to transition between.\r\n\r\n### Actual behaviour\r\n\r\nDepending on the initial amount of items in the swiper, if additional items are added, those additional items will not render correctly. They'll appear blank, and when swiping back to one of the pre-existing items (from the blank views) the transition animation will not occur and instead will jump straight to the item (however swiping between the pre-existing items will have the transition animation).\r\n\r\n### Steps to reproduce\r\n1. Create a swiper with a certain amount of items.\r\n2. Call setState increasing the amount of items in the swiper.\r\n3. Swipe between the items to see the issue.\r\n\r\n### Additional notes\r\n\r\nThe issue seems to be directly related to the swiper's initial state. So if the swiper is initially created with 5 items, then it will only be able to stay at 5 or go lower. Increasing it will cause this issue.\r\n"},"comment":{"url":"https://api.github.com/repos/leecade/react-native-swiper/issues/comments/331392742","html_url":"https://github.com/leecade/react-native-swiper/issues/538#issuecomment-331392742","issue_url":"https://api.github.com/repos/leecade/react-native-swiper/issues/538","id":331392742,"user":{"login":"bdavid68","id":15665426,"avatar_url":"https://avatars0.githubusercontent.com/u/15665426?v=4","gravatar_id":"","url":"https://api.github.com/users/bdavid68","html_url":"https://github.com/bdavid68","followers_url":"https://api.github.com/users/bdavid68/followers","following_url":"https://api.github.com/users/bdavid68/following{/other_user}","gists_url":"https://api.github.com/users/bdavid68/gists{/gist_id}","starred_url":"https://api.github.com/users/bdavid68/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bdavid68/subscriptions","organizations_url":"https://api.github.com/users/bdavid68/orgs","repos_url":"https://api.github.com/users/bdavid68/repos","events_url":"https://api.github.com/users/bdavid68/events{/privacy}","received_events_url":"https://api.github.com/users/bdavid68/received_events","type":"User","site_admin":false},"created_at":"2017-09-22T09:02:46Z","updated_at":"2017-09-22T09:02:46Z","author_association":"NONE","body":"@ScrimpyCat Did you find a solution?"}}
{"actor":{"display_login":"bdavid68"}}