Fix: Add Optional swiperElementNodeName
Prop for (non swiper-element) Web Component Usage
#7284
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Our design system team recently ran into some major rendering issues using Swiper internally with some of our LitElement based web components (slotted children slides aren't detected).
After doing some digging, I stumbled across the change added in #6870 which uses a hard-coded nodeName to ultimately determine if a particular swiper instance is rendering as a web component or not.
This PR should allow continued Swiper usage (as-is) via the
swiper-container
custom element, yet also help other folks with customized web component usage by using this newswiperElementNodeName
parameter to define the custom element tag name being used in their implementation.