Front end

SCSS extend against mixin

The same component built both ways, with the compiled CSS side by side. One groups your selectors, the other repeats the declarations, and the difference matters more than the byte count suggests.

Using extend

compiles to

Using a mixin

compiles to

What the difference costs you

View Comments (4)

Leave a Reply

Subscribe to My Newsletter

Subscribe to my email newsletter to get the latest posts delivered right to your email. Pure inspiration, zero spam.

Discover more from Discuss Data Science, Machine Learning and Analytics

Subscribe now to keep reading and get access to the full archive.

Continue reading