akiran / akiran/react-slick

Problem with paging

Offen
#1,500 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
Vorherrschende Sprache
JavaScript
Sterne
11.9k
Forks
2.1k
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

Hi, I'm trying to call a function everytime I click on a page of Slick. I could do it but I've found that they work together. I'll get you in context showing my code:

```
const show = (element) => console.log(element);
...
const settings = {
customPaging: (i) => {
return (


{i + 1}

);
},
...
```
If I click to any of the pages, I don't know why it shows all the values on the console. I would like to show just the value of the item that I'm clicking. For example, if I'm clicking to the page 3 I want to show on the console a '3'.

Do you know how could I do it? Thanks!

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.