Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

296
Views
react-paginate class applied but not getting the styles

i use react-paginate package and for styling, I use styled-components in the react-paginate docs, it says to give the container a class I should use the className property for CSS in js libraries like styled components and for normal CSS I should use containerClassName I used both of them but none worked for styled-components the problem is it's getting the class i.e .container class but the styles won't apply the other classes like .active works but it's just the .container which is not getting the styles here's the code

import ReactPaginate from "react-paginate";
import styled from "styled-components";
const StyledReactPaginate = styled(ReactPaginate)`
  a {
    cursor: pointer;
  }
  .active {
    background: lime;
  }
  .container{
  display: flex;
  }
`;
const Pagination = (props) => {
  return (
    
      <StyledReactPaginate
        previousLabel={props.previousLabel}
        nextLabel={props.nextLabel}
        pageCount={props.pageCount}
        onPageChange={props.onPageChange}
        activeClassName={"active"}
        className={"container"}
      />
 
  );
};

export default Pagination;

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!