Virtual Slides in Swiper.js: Container Height Fails to Recalculate After Dynamic Content Change
0 reputation · 02 May 2020, 05:36 UTC
Problem Statement
When using Swiper.js with the Virtual Slides module in vertical mode, the container height does not adjust after the content of a slide changes post‑initialization.
Constraints
The instance is configured with virtual: true, direction: 'vertical', and slidesPerView: 'auto'. The issue appears in Swiper 8.x and 9.x.
Questions
1. Does Swiper’s Virtual Slides module recalculate the container height automatically when the inner content of a rendered slide changes?
2. If not, is there a documented event or method that should be called to trigger a height update?
3. Does the problem persist when using slidesPerView: 1 instead of 'auto'?