Less Hover Mixin

Glenn Glenn's Blog 0 Comments

Not redly publicised but ever so simple:- [css] /* Button*/ .button { // Normal CSS Classes background: @white; &:hover { // adding my own hover state for button background: @black; } } [/css] Rather than ‘class:hover’ we use &:hover and then add our css / less below.