react-slick stacks slides vertically
See original GitHub issueimport React from ‘react’; import Slider from ‘react-slick’;
const settings = { arrows: false, dots: false, infinite: true, speed: 500, slidesToShow: 1, slidesToScroll: 1 };
const generateSlides = ({slides}) => {
if(slides){
return (
<Slider {…settings}>
<div>
{slides.map(function(item){
return (
<div key={item.id} className=“item_slider”
style={{background:url(/images/covers/${item.cover})
}}>
<div className="caption">
{item.topic}
{item.title}
</div> </div> ) })} </div> </Slider> ) } }const Featured = (props) => { return( <div> {generateSlides(props)} </div> ) }
export default Featured;
Issue Analytics
- State:
- Created 5 years ago
- Comments:12
Top Results From Across the Web
Slick vertical slider issue - Stack Overflow
If I change the variable slidesToShow to 1, the arrows come back again but then I need to change the vertical padding to...
Read more >API - React Slick Documentation - neostack
Description: Adjust the slide's height automatically ... Description: Center current slide ... vertical. Type: bool. Default: false. Description: ...
Read more >react-slick-vertical - npm
Property Type Working
className String Yes
adaptiveHeight bool Yes
arrows bool Yes
Read more >Creating a carousel with ReactJS Slick - GeeksforGeeks
Approach: By using the React Slick package, we will create an image slider. In the process, we will use a number of available...
Read more >Slick slider vertical example - JSFiddle - Code Playground
Test your JavaScript, CSS, HTML or CoffeeScript online with JSFiddle code editor.
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 Free
Top 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
For anyone arriving at this from google:
It may be because the container in which you have your Slider has a non-compatible display mode, try display: block
<DivWithBlockDisplay> <Slider> <div /> <div /> </Slider> </DivWithBlockDisplay>
@neemssoni @Sailias I’m not sure I’m really helpful at this point, but have you tried importing “slick-carousel” styles in your app? Such as: