Skip to content

Setting virtual.enabled: false removes all slides instead of showing them normally #7977

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

Open
5 of 6 tasks
schardev opened this issue Apr 29, 2025 · 0 comments
Open
5 of 6 tasks
Labels

Comments

@schardev
Copy link

Check that this is really a bug

  • I confirm

Reproduction link

https://codesandbox.io/p/devbox/swiper-react-virtual-slides-forked-rgqhyf

Bug description

When I disable the virtual slides feature by setting virtual: { enabled: false }, all the slides disappear from Swiper. I expected that disabling virtual mode would just make Swiper show all the regular (non-virtual) slides, but instead, everything gets removed from the DOM.

Expected Behavior

Disabling virtual mode should just switch back to showing all the slides normally, without removing them from the DOM.

Actual Behavior

All the slides get removed when virtual.enabled is set to false.

Swiper version

11.2.6

Platform/Target and Browser Versions

Arch Linux (Chrome 136)

Validations

  • Follow our Code of Conduct
  • Read the docs.
  • Check that there isn't already an issue that request the same feature to avoid creating a duplicate.
  • Make sure this is a Swiper issue and not a framework-specific issue

Would you like to open a PR for this bug?

  • I'm willing to open a PR
@schardev schardev added the React label Apr 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant