Bug: Slide component does not load when carousel's parent component is imported 0.6.8
See original GitHub issueHello, I ran into an odd issue where the Carousel doesn’t display until I click on where the slide would be or trigger a pageChange by clicking on a pagination icon. Even stranger is that the elements are all there in the markup, but they won’t display until i click in the general area of the slider.
This only seems to occur when I import the components into another component that is being imported as well.
import Vue from 'vue'
import ProductOverview from './components/product-overview.vue'
const app = document.getElementById("app")
new vue({
el: app,
template: "<ProductOverview />",
components: { ProductOverview }
})
<template>
<div class="product">
<product-images></product-images>
<product-form></product-form>
</div>
</template>
<script>
import ProductImages from "./product-images.vue";
import ProductForm from "./product-form.vue";
export default {
components: {
ProductImages,
ProductForm
}
};
</script>
<template>
<carousel>
<slide>
<img src="https://placehold.it/600x400">
</slide>
<slide>
<img src="https://placehold.it/600x400">
</slide>
</carousel>
</template>
<script>
import { Carousel, Slide } from "vue-carousel";
export default {
components: {
Carousel,
Slide
}
};
</script>
Here are some screenshots as well.
I click on one of the pagination circles:
Issue Analytics
- State:
- Created 6 years ago
- Comments:31 (10 by maintainers)
Top Results From Across the Web
Can I reference component props to get from parent when I ...
I am working o a project with multiple carousels. so I decided to create a carouselitem.js component, a carousel.js component that includes ...
Read more >Bootstrap Vue Carousel Does Not Work When Imported As ...
A slideshow component for cycling through elementsimages or slides of the carousel will avoid sliding when the webpage is not visible to the...
Read more >ng-zorro-antd | Yarn - Package Manager
An enterprise-class UI design system for Angular applications. 60+ high-quality Angular components out of the box. Written in TypeScript with predictable static ...
Read more >stream-chat-react - UNPKG
node_modules/html-to-react/lib/should-process-node-definitions.js",". ... node_modules/emoji-mart/dist-es/components/not-found.js",".
Read more >Untitled
Jack's mannequin the mixed tape mp3, 8 week embryo not growing, ... E/m key components, Chemical biological interactions, Glee whistle lyrics, ...
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
I had the same problem, and my solution is:
@nchlodzi indeed an unfortunate bug, but I believe this may be solved with #172. However, I’m not entirely sure.
I was able to get some results with by setting the
VueCarousel-slide
style to this:Try that instead of the
VueCarousel-inner
It’s a workaround, but it should display the slides by default with that.