Extra warnings Swiper Loop in SvelteKit
alkorlos opened this issue · comments
Check that this is really a bug
- I confirm
Reproduction link
Bug description
In the example, there are two sliders. Currently, there are two issues with Swiper Loop Warning: The number of slides is not enough for loop mode, it will be disabled and not function properly. You need to add more slides (or make duplicates) or lower the values of slidesPerView and slidesPerGroup parameters
First issue: For the second slider, the warning is triggered twice.
Second issue: For the first slider, the warning is mistakenly triggered. It occurs only when there's a second slider with 'number of slides is not enough for loop mode' placed after the first slider in the code. If you swap the sliders in the code, the first slider won't have this warning.
In Swiper Element, this issue doesn't exist.
I check "Make sure this is a Swiper issue and not a framework-specific issue *", but I don't know how to check for sure this problem is on the Swiper side or in SvelteKit. If it's on the SvelteKit side, perhaps you can help open a well-formulated issue in their repository, if simply report this issue, it will be closed as a component issue.
Expected Behavior
Triggered warning only once.
No mistakenly warning.
Actual Behavior
Triggered warning twice.
Mistakenly warning.
Swiper version
11.1.1
Platform/Target and Browser Versions
Chrome 124
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