Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

the loadMinimal logic may have a mistake #1374

Open
xiangjiu0918 opened this issue Nov 29, 2024 · 0 comments
Open

the loadMinimal logic may have a mistake #1374

xiangjiu0918 opened this issue Nov 29, 2024 · 0 comments

Comments

@xiangjiu0918
Copy link

Which OS ?

windows

Version

Which versions are you using:

  • react-native-swiper v?1.6.0-rc.2
  • react-native v0.?.?0.73.0

Expected behaviour

​​​​The real last swiper should be keep
react-native-swiper1

Actual behaviour

The real penultimate swiper was kept.
swiper-screenshot

I read the source code and I think it's on line 836 should be 'loop && i === total ' instead ‘loop && i === total - 1’.

How to reproduce it>

<Swiper loadMinimal={true} loop={true}> <Image style={DetailStyle.image} resizeMode='contain' source={require('@/static/defaultAvator.jpeg')} /> <Image style={DetailStyle.image} resizeMode='contain' source={require('@/static/defaultAvator.jpeg')} /> <Image style={DetailStyle.image} resizeMode='contain' source={require('@/static/defaultAvator.jpeg')} /> <Image style={DetailStyle.image} resizeMode='contain' source={require('@/static/defaultAvator.jpeg')} /> <Image style={DetailStyle.image} resizeMode='contain' source={require('@/static/defaultAvator.jpeg')} /> <Image style={DetailStyle.image} resizeMode='contain' source={require('@/static/defaultAvator.jpeg')} /> <Image style={DetailStyle.image} resizeMode='contain' source={require('@/static/defaultAvator.jpeg')} /> </Swiper>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant