سؤال

I have been looking around how to use mixins with regular css3, no sass or less, so I was wondering if that was possible. All I want to do is:

@mixin .clientred{
    color:darkred;
}

in a nutshell so then I could use it later

h1{
    include: .clientred;
    font-size: 32px;
}
هل كانت مفيدة؟

المحلول

CSS3 does not support any notion of mixins.

That is only available using a CSS compiler like SASS or LESS. (That's kind of the whole point of using compiled CSS... if CSS had it built in, we wouldn't need the compilers.)

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top