YIZHUANG / react-multi-carousel

A lightweight production-ready Carousel that rocks supports multiple items and server-side rendering with no dependency. Bundle size 2kb.
MIT License
1.25k stars 286 forks source link

Responsive prop #355

Open Safwa9amar opened 1 year ago

Safwa9amar commented 1 year ago

throwError.js:1 Uncaught Error: Responsive prop is needed for deciding the amount of items to show on the screen

react 18

palya commented 1 year ago

You need to provide structure like this, with amount of items you want to show initially:

      const responsive = {
        desktop: {
          breakpoint: { max: 40000, min: 900 },
          items: 4
        },
        mobile: {
          breakpoint: { max: 900, min: 0 },
          items: 2
        }
      };