F21 F21 - 2 months ago 5
Sass (Sass) Question

Including another class in SCSS

I have this in my SCSS file:

display: inline-block;
//some other properties
color: darken(#FFFFFF, 10%);


//Inherite class-a here

//some properties

In class-b, I would like to inherite all properties and nested declarations of
. How is this done? I tried using
@include class-a
, but that just throws an error when compiling.

F21 F21

Looks like @mixin and @include are not needed for a simple case like this.

One can just do:

.myclass {
  font-weight: bold;
  font-size: 90px;

.myotherclass {
  @extend .myclass;
  color: #000000;