wwwaiser / react-js-pagination

http://vayser.github.io/react-js-pagination
Creative Commons Zero v1.0 Universal
353 stars 95 forks source link

Active class not being added #72

Closed AWR14 closed 4 years ago

AWR14 commented 5 years ago

reopening this https://github.com/vayser/react-js-pagination/issues/37

Anyone else had this issue and found a solution or idea why its doing it?

ChocolateSlayer commented 5 years ago

For me this didn't work when I passed String value to the activePage property.

<Pagination activePage={"1"} //Doesn't work activeLinkClass="paginationlink paginationlink_active"/>

<Pagination activePage={Number("1")} // Works well activeLinkClass="paginationlink paginationlink_active"/>

sleyderzm commented 5 years ago

For me this didn't work when I passed String value to the activePage property.

<Pagination activePage={"1"} //Doesn't work activeLinkClass="paginationlink paginationlink_active"/>

<Pagination activePage={Number("1")} // Works well activeLinkClass="paginationlink paginationlink_active"/>

i have the same issue and work parsing to Number, thanks a lot