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

Swiper changes layout when swiper component is destroyed #4443

Closed
orjandh opened this issue Apr 14, 2021 · 1 comment
Closed

Swiper changes layout when swiper component is destroyed #4443

orjandh opened this issue Apr 14, 2021 · 1 comment
Labels

Comments

@orjandh
Copy link

orjandh commented Apr 14, 2021

  • Swiper Version: 6.5.6
  • Platform/Target and Browser Versions: Chrome, and others.

What You Did

I am having some visual glitches in my layout when navigating away from a page containing a swiper component, with transitions. I have isolated the issue to the destroyment of the swiper component and created a minimal reproducible example.

To reproduce: Open the stackblitz example and click the destroy button. Notice how this changes the layout.

https://stackblitz.com/edit/swiper-angular-example-ptbxfh?file=src%2Fapp%2Fapp.component.html

Expected Behavior

I expect the layout to be untouched when the component is destroyed. But I do of course expect the swiping functionality to cease to function.

Actual Behavior

When the swiper component is destroyed, it updates the layout with what seems to be the default configurations. This among other are a slidesPerView of 1.

@ThierryStaar
Copy link

Hello,
I've got the same problem and it occurs also on theses other plugins I've tried : owl-carousel, slick carousel

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

2 participants