Cards are not being loaded into Swiper
See original GitHub issueThank you for this awesome library!
I am having some difficulties adding new cards to the swiper. I am using Redux for state management, and put the loaded cards directly into the swiper.
Initially the 15 loaded cards are working out fine, but when loading additional cards the internal state.cards
are not being updated.
Here’s the issue reproduced in Snack: https://snack.expo.io/BJVQ81oo4. See the console log, click Add cards and start swiping. Audi and Mercedes won’t show.
Issue Analytics
- State:
- Created 4 years ago
- Comments:8 (1 by maintainers)
Top Results From Across the Web
Issues showing new cards after paginated data is returned ...
Issue When dynamically adding elements to the Swiper card prop, the newly added properties will not appear on the screen.
Read more >Credit Card Swiper Troubleshooting - MINDBODY Support
This article provides tips and possible solutions when your credit card swiper isn't reading swipes, is reading them incorrectly, or isn't working at...
Read more >Swiper JS slider external javascript file is not being loaded
I am using Thymeleaf and displaying the content of a table in a bunch of cards. I tried swiper without Thymeleaf and the...
Read more >Swiper API
Swiper is the most modern free mobile touch slider with hardware accelerated transitions and amazing native behavior.
Read more >Swiper—Jumping on Page Load Resolved | by Aaron K.
The original Swiper demo jumps around and flickers on page load. Ugh. For an unknown reason it was not apparent until many days...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@migcv @shadiramadan I’ve fixed it for my use case in this branch.
I didn’t test it thoroughly, so milage may vary depending on the features you use
@OriginLive, basically @patrickreck added the getDerivedStateFromProps function to the component to update the state. (the commit: https://github.com/patrickreck/react-native-deck-swiper/commit/7499c942bfaadc8fff9b2788aff52b43a2ea0696)