CSS not imported and affecting my component

UI Components for React
Post Reply
Posts: 1
Joined: 07 Feb 2023, 09:36

07 Feb 2023, 10:07

i made a login page and a signup page each with a seprate css file and using prime react and it doesn't matter in which css file i change anything it affects all pages

Posts: 61
Joined: 24 Aug 2022, 13:17

09 Feb 2023, 10:00

I have identified a few potential causes for the issue, and I would like to share them with you:
Global scope: Your CSS styles are global by default, meaning that changes made to the CSS file will apply to all instances of that element throughout your site if you haven't scoped your styles to specific elements.
Import statements: If you have imported the same CSS file into multiple pages, changes made to that file will affect all pages that have imported it.

If these causes do not resolve the issue, I request that you provide a reproducer (code sandbox etc.) example.
Bugra Beyduz
PrimeReact Core Developer
Github profile: https://github.com/habubey

Posts: 6
Joined: 03 Mar 2023, 12:06

24 Mar 2023, 12:23

It is possible that both the login and signup pages are referencing the same CSS file, or that both CSS files are linked in the same HTML file. Check to ensure that each page is referencing the correct CSS file.

Post Reply

Return to “PrimeReact”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 1 guest