This is just the source code of an exercise I do after a talk about "How to write clean CSS and BEM naming notation"
-
A basic knowledge of React
-
NodeJS 10.13.0. I recomend using NVM to manage Node versions on your machine
Clone the repo
git clone git@github.com:samfcmc/style_rules_exercise.gitInstall dependencies
npm installStart the local server
npm startThe server will start. Just open your browser and type the URL that is being shown in your terminal. You can make changes to the source code and them will be immediately reflected in the browser.
The main component (App) is loading the SectionMess component.
Inside the client/src/components folder open SectionMess.js and SectionMess.styl files. The class names and all of the style rules are a totally mess. See if you can make it look nice and clean.
Use BEM notation for that ;)
The .styl file is a Stylus that is later transpiled to CSS. You don't need to worry about this process, because this project uses Parcel that handles everything for you.
Happy coding :)