Pregunta

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;
}
¿Fue útil?

Solución

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.)

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top