Pagnization does not work with dynamic components
See original GitHub issueWhich OS ?
iOS
Version
Which versions are you using:
- react-native-swiper v1.5.6
- react-native v0.49
Expected behavior
Pagnization dots indicate current swipe-item’s index
Actual behavior
only the first dot is highlighted
I have tried to use a few hard-coded mock CardResume
and the paganization works fine with correct indication, but once I switch to using map
the paganization indicators stopped working
```
<Swiper
style={{}}
height={height*0.7}>
{this.state.resumeList.map((resumePreview, index) => {
this.fakedata.resumeName = resumePreview.headline
return (
<CardResume
key={index}
style={{margin: "5%"}}
data={this.fakedata}
onPress={() => this.props.navigation.navigate('Details', { resumeID: resumePreview.profile_id })}
/>
)
})}
</Swiper>
Issue Analytics
- State:
- Created 6 years ago
- Reactions:3
- Comments:20
Top Results From Across the Web
Dynamic page pagination is not working in react table
If that's really what you want and your problem is the non-displayed values, it works by changing MenuItem to option , with both...
Read more >Dot does not work properly while rendering dynamic array ...
while rendering dynamic components(eg. rendering screens in an array or use map) active dot will remain at the initial position no matter which ......
Read more >Pagination - Bootstrap
Pagination is built with list HTML elements so screen readers can announce the number of available links. Use a wrapping <nav> element to...
Read more >How To Build a Reusable Pagination Component with Vue.js
These will be our dynamic props. Although we want to render a range of pages, we do not want to render all available...
Read more >Dynamic Query Component - Bloomreach
Class Name; Purpose; Component Parameters; Component request parameters; Pagination Attributes; Page Attributes. This feature is available since Bloomreach ...
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 FreeTop 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
Top GitHub Comments
I did just like this and it works fine
It looks like the problem is the swiper component isn’t resetting when the slides change.
Setting the key on the swiper to change (e.g.
key={images.length}
) when the underlying array changes also fixes this: