使用萨斯开发样式表, even when using its most basic features, 比如嵌套属性或变量, saves valuable time and makes life easier for 前端开发人员. It’s not surprising that CSS pre-processors have been widely adopted as the de facto way of creating styles for websites and applications; we simply can’t live without them anymore.
当涉及到 主题; that is, changing the look and feel of your website while maintaining its layout, 萨斯’ features—like mixins or 函数s—can feel like taking a plane instead of walking! 在本SCSS教程中, we’re going to create a minimal theme and use SCSS to give our CSS programming some superpowers.
一个基本的Mixin方法
Let’s say we have the following layout: