Initial Carousel Blank
See original GitHub issueBug is related to
- embla-carousel (core package)
- embla-carousel-react
- embla-carousel-autoplay
- embla-carousel-docs (documentation website)
Embla Carousel version
- v6.0.2
Describe the bug
Embla carousel is initially blank, and needs to be resized before it renders the image. This happens only sometimes and randomly. I have read the other issues regarding the same, but none of the tehniques work, I understand its a reinitializing issue but cannot figure out how to make it work. I am using it with NextJs 12.
I have the sample code to get started in this github repo - https://github.com/kush-daga/emblademo
CodeSandbox
- The link to a CodeSandbox that demonstrates the bug clearly.
Steps to reproduce
1.Clone the https://github.com/kush-daga/emblademo repo, and yarn dev
.
2. Initially its a blank screen, resize to view images.
Expected behavior
- Carousel should work in the first render
Additional context
Issue Analytics
- State:
- Created 2 years ago
- Comments:21 (9 by maintainers)
Top Results From Across the Web
bootstrap 3 carousel abnormal: blank content appears when ...
bootstrap 3 carousel abnormal: blank content appears when go "prev" before the 1st slider item, but working perfect as long as click "next"....
Read more >Why is MDB Carousel showing empty starting slide on page loa
Hello everyone,. I am trying to use the MDB carousel for a simple image slider in an angular project. All my images are...
Read more >Carousel blank when changing tab for the first time. Will ...
When I run my app, the carousel on the first screen works as expected. But when I change tab to my second screen,...
Read more >Free The First Blank Page Template - Instagram - PicMonkey
The First Blank Page - Instagram Carousel Ad Template. 1080 x 1080 px. To use this template, go to PicMonkey.com on your desktop....
Read more >449180 - Blank slide at the beginning of Carousel animation ...
Issue 449180: Blank slide at the beginning of Carousel animation upon returning ... The carousel should display one slide or two slides next...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@kush-daga I’ve just released the Auto Height plugin with v6.1.0. Here’s the release details. Just make sure your slides have their natural height before initializing Embla so Embla can pick them up. So don’t set
height: 0;
on your slides or similar.Best, David
@kush-daga thank you for sharing 👍🏻.
Just wanted to let you know that what you want to achieve will be available as an Embla plugin as soon as I get some time to make it:
Best, David