Include styles with the <Slider> component to avoid unnecessary global styles.
Offen
- Vorherrschende Sprache
- JavaScript
- Sterne
- 11.9k
- Forks
- 2.1k
- PR-Merge-Kennzahlen
- Keine gemergten PRs in 30 T.
Beschreibung
When using the library with Next.js, you can't include the styles at a component level just for the pages / components using the slider. You have to import it globally, causing additional unnecessary CSS.
There should be a parameter for the `` component that includes the default `slick.css` and `slick-theme.css`, such as:
```
const settings = {
dots: true,
infinite: true,
speed: 500,
slidesToShow: 4,
slidesToScroll: 4,
styles: true
};
...
```
Beitragsleitfaden
Bewertung
Dieses Issue wurde noch nicht bewertet.