https://try.github.io/levels/1/challenges/1
https://www.codecademy.com/learn/learn-git
- Do not use ID for styling. IDs are for javascript use only.
- Nesting is not great idea. Rather write longer names. We have autocompletion.
// BAD
.card .content .meta span {
color: #00c;
}
// GOOD
.card__content__meta__text {
color: #00c;
}
- Use BEM methodology - http://getbem.com/naming/
.block {}
.block__element {}
.block__element.state {}
.block__element--modifier {}
.button {}
.button.disabled {}
.button__text {}
.button--danger {}
.button--success {}
- Try to not use
!important
.
https://specificity.keegan.st - you don't need to use it for your selectors, just to realise how it works.