$variables: value;
형태로 변수를 할당할 수 있다.
변수는 재할당이 가능하며 아래를 보고 적용 범위를 확인 할 수 있다.
//scss
$size: 333px;
.container {
position: fixed;
top: $size;
.tiem {
$size: 777px;
width: $size;
height: $size;
transform: translate($size);
.li{
$size: 999px;
margin: $size;
}
.a{
border: $size;
}
}
width: $size;
}
.box {
padding: $size;
}
//css compile
.container {
position: fixed;
top: 333px;
width: 333px;
}
.container .tiem {
width: 777px;
height: 777px;
transform: translate(777px);
}
.container .tiem .li {
margin: 999px;
}
.container .tiem .a {
border: 999px;
}
.box {
padding: 333px;
}