DEV Community

Discussion on: Discuss: Would you have one style sheet for all or make a style sheet for each page when making a basic website?

Collapse
 
xwero profile image
david duymelinck

A good way to split up the css files in a crucial css file and a page specific css file.

The crucial file is the easiest file. It contains css that is used on every page.
Most of the times specific content of the pages are build up with components. So you can split up css files in components and generate css files with all the components combinations there are.
Once a page is created or changed, there needs to be a component check to link to the css file with the right component combination.