- Mastering Responsive Web Design
- Ricardo Zea
- 234字
- 2021-07-16 20:33:18
Chapter 1. Harness the Power of Sass for Responsive Web Design
Before we dive into mastering responsive web design, we need to be on the same page as far as technologies go, in our case, CSS preprocessors and, specifically, Sass.
In this book, all CSS is going to be written in Sass in SCSS format. The way we write CSS has changed; it has improved tremendously.
CSS preprocessors such as Sass, LESS, and Stylus give the web/mobile designers and developers new superpowers. Yes, I used the word superpowers because that's exactly how I felt only a few hours after using Sass for the first time, and what I used was as basic as it gets:
.navigation-bar { display: flex; li { padding: 5px 10px; } }
See the nested li
selector? Yeah, that's Sass in action. When the preceding code is compiled, this is what it looks like:
.navigation-bar { display: flex; } .navigation-bar li { padding: 5px 10px; }
Tip
Downloading the example code
You can download the example code files from your account at http://www.packtpub.com for all the Packt Publishing books you have purchased. If you purchased this book elsewhere, you can visit http://www.packtpub.com/support and register to have the files e-mailed directly to you.
Let's see what's in store for us in this chapter:
- 軟件安全技術
- 自己動手實現Lua:虛擬機、編譯器和標準庫
- Programming ArcGIS 10.1 with Python Cookbook
- INSTANT Mercurial SCM Essentials How-to
- Spring Boot Cookbook
- R大數據分析實用指南
- Java面向對象程序設計
- 移動互聯網軟件開發實驗指導
- Android驅動開發權威指南
- Vue.js 2 Web Development Projects
- R語言:邁向大數據之路(加強版)
- OpenCV 3計算機視覺:Python語言實現(原書第2版)
- Visual C++開發寶典
- Python預測之美:數據分析與算法實戰(雙色)
- Java 9:Building Robust Modular Applications