react-splide
react-splide copied to clipboard
Splide is not responsive on element resize without window resize
Checks
- [X] Not a duplicate.
- [X] Not a question, feature request, or anything other than a bug report directly related to React Splide. Use Discussions for these topics: https://github.com/Splidejs/splide/discussions
Version
0.7.12
Description
When resizing the window splide updates the position of a photos correctly but when the component is resized without changing the window size the position of photos in splide is not updated
Reproduction Link
No response
Steps to Reproduce
- Create resizable parent component that will render Splide inside
- Resize the component while any photo except the first one is currently displayed
- Photos have wrong position
Expected Behaviour
Correctly handle responsiveness when the size of the element is updated by changing the size of a component without changing the size of a window. Adding resize observer on an element and refreshing splide on element size updates resolves the problem.