Sass is a meta-language that extends CSS by adding features like nested rules, variables, mixins, selector inheritance, and more. It allows for more modular and maintainable CSS code. Sass code is translated to standard CSS using a command line tool or web framework plugin. Some benefits of Sass include reducing redundant code through variables and mixins, and creating more scalable and maintainable style sheets through features like nesting and imports. Sass supports both .sass and .scss syntax and files can be compiled to CSS using the sass or compass command line tools.
Presentation for HTTQ in February 2013 by Ben Byrne on the CSS Preprocessor SASS, including getting it installed with ruby, sass and scss syntax, common Compass mixins, and sprites.
This document introduces Sass (Syntactically Awesome Style Sheets), which is a CSS preprocessor that adds powerful features like variables, nested rules, mixins, inheritance, and other useful tools that help make authoring CSS easier and more maintainable. It discusses some of the key benefits of using Sass like variables, nesting, mixins, functions, and operations that make styling more powerful and repetitive tasks easier. It also covers using Compass, a Sass extension framework, to gain access to useful CSS3 mixins and functions.
Sass is a scripting language that is interpreted into Cascading Style Sheets (CSS). SassScript is the scripting language itself. Sass consists of two syntaxes. The original syntax, called "the indented syntax", uses a syntax similar to Haml.
The document provides an overview of Less, a CSS preprocessor language that extends CSS to make it more readable and maintainable. Less adds features like variables, mixins, operations, and functions to allow variables, nested rules, and more. It compiles to plain CSS. Topics covered include Less syntax and features, installation and usage options, built-in functions, and alternatives like Stylus and SASS.
Advanced Technology for Web Application DesignBryce Kerley
?
This document provides an overview and introduction to advanced technologies for web design, including HAML, SASS, Compass, CoffeeScript, Rake, and Charleston. HAML and SASS are markup languages that can simplify and improve HTML and CSS. Compass is a CSS meta-framework built with SASS. CoffeeScript is a programming language that compiles to JavaScript. Rake is a build tool that can be used with these technologies. Charleston is a static site generator that bundles Rake rules for using HAML, SASS, and CoffeeScript together on a project. Installation and usage instructions are provided for each technology.
HTML5, CSS, JavaScript Style guide and coding conventionsKnoldus Inc.
?
Coding conventions are style guidelines for any programming language. As, we are growing ourselves rapidly in learning new technology, the need for learning of the coding standards and conventions for the same language also arises.
So, here let us try to learn some coding guidelines for few frontend languages.
The document discusses CSS pre-processing with SASS and LESS. It begins with an introduction and disclosure by the author. The agenda then covers what CSS preprocessors are, why they are used, possible issues, how they work with basic examples, a comparison of SASS and LESS, and whether preprocessors should be tried. SASS is argued to be more robust with features like conditional statements, loop statements, and the Compass toolkit, making it a better choice than LESS overall.
Compass, Sass, and the Enlightened CSS DeveloperWynn Netherland
?
This document discusses Sass, Compass, and the enlightened web. It describes how Sass provides powerful features like variables, nested rules, mixins, selector inheritance and functions that allow developers to write more maintainable CSS. Compass is a library of Sass extensions that provides CSS3 mixins. Together, Sass and Compass allow developers to write stylesheets in a more simplified and structured way.
Sass is an extension of CSS3 that adds power and elegance to the basic language. It allows you to use variables, nested rules, mixins, inline imports, and more, all with a fully CSS-compatible syntax. (With a little help from Ruby) This talk will cover an overview of what Sass is, how to get it, run it, and use it, and show some examples of its magic.
Code examples at: https://github.com/founddrama/vt-code-camp
Elegant CSS Design In Drupal: LESS vs SassMediacurrent
?
This document compares LESS and SASS, which are meta-languages that extend CSS to allow variables, mixins, and other features. LESS processes stylesheets with JavaScript, while SASS uses the Ruby programming language. Both aim to make CSS more modular and reusable. The document discusses how each works, their differences, who created them, how Drupal supports them with modules, and key concepts like variables, mixins, and functions. It recommends that SASS will likely power Drupal 8's styling and provides additional learning resources.
This is a presentation I gave on Sept. 25, 2012 for the Winnipeg PHP Group on some of the features in LESS I have started using in my own development environment.
This document discusses accelerated CSS techniques using tools like CSS frameworks, JavaScript, and CSS preprocessors. It introduces concepts like nested rules, variables, mixins, extends, imports, and powerful functions in CSS preprocessors that allow generating complex CSS from simpler code. CSS frameworks like Blueprint and modules for CSS3 properties are demonstrated. Image sprites are also mentioned briefly.
Sass and Less are CSS preprocessors that add features like variables, nesting, mixins, and inheritance to regular CSS. Sass was designed by Hampton Catlin and developed using SassScript, while Less was designed by Alexis Sellier and allows real-time compilation via Less.js. Both preprocessors provide mechanisms for variables, nesting, mixins, and more to make writing CSS more efficient.
Using different kind of tools to build big styles for websites. Problem with big CSS is that it gets heavy, hard to manage, convoluted. But fortunately there are ways to keep structured and manageable. In this presentation we introduce combination of Makefile, SASS, ImageMagick, and other tools.
Sass is a preprocessor scripting language that is compiled into CSS. It allows for nesting, variables, mixins, and other advanced features to help manage large CSS codebases. The document discusses how to install and use Sass via the command line as well as with GUI tools. Key Sass features covered include variables, nesting, parent selectors, combining selectors, imports, extends, and mixins.
Breaking Free from Bootstrap: Custom Responsive Grids with Sass SusyJames Steinbach
?
Instead of relying on heavy, pre-formatted, markup-intensive CSS frameworks for grids, we can use a Sass grid framework to write clean, maintainable, performant CSS grid layouts.
twitter.com/jdsteinbach
jamessteinbach.com
Bringing sexy back to CSS: SASS/SCSS, LESS and CompassClaudina Sarahe
?
ºÝºÝߣ from a presentation given at 2011 Design for Drupal in Boston about two popular CSS extensions and Compass with a focus on how they integrate in Drupal environment. The goal is to present and overview of Sass and LESS in order to drive front-end developers to abandon plain old CSS. Compass is talked about as the reason to use Sass over LESS.
This document summarizes Sass (Syntactically Awesome Style Sheets), which is a preprocessor scripting language that extends CSS by adding features like variables, nested rules, mixins, inheritance, and other utilities. It discusses Sass features such as variables, nesting, mixins, functions, conditionals, and more. It also covers Compass, a Sass extension library and framework, which provides additional features like sprites, gradients, and vendor prefixing. Finally, it provides instructions for installing and using Sass and Compass on different platforms.
The document discusses adaptive theming using Compass and Susy grid. It covers using SCSS for file structure, implementing a Susy grid, responsive images, abstract classes and mixins, and optimizing the site. Mobile-first development and responsive design principles are emphasized. Key aspects covered include fluid grids and media, SCSS file structure, using Susy grid mixins, responsive mixins, resetting columns, and bonus techniques like abstract classes and mixins.
Rob Walker from Papertrail takes us through his recent journey from regular CSS to SCSS. If you¡¯re thinking of making the switch yourself and just need a little push, this is the talk for you.
Sass & Compass is a presentation about Sass, a CSS preprocessor, and Compass, an extension of Sass. It discusses features of Sass like variables, nested rules, and mixins that add functionality to CSS. It also covers how to set up and use Compass, which provides CSS3 properties and helpers through Sass mixins. The presentation provides examples of how these Sass features compile to regular CSS.
The document discusses Haml and Sass, which are template languages used to generate HTML and CSS respectively. Haml uses indentation and special characters to structure markup concisely while Sass allows nesting, variables, and other features to simplify CSS authoring. The document provides examples of basic Haml and Sass syntax and recommends starting with individual templates, using the proper file extensions, and checking whitespace when errors occur.
SASS is an extension of CSS that adds powerful features like variables, mixins, functions and more. It allows reusability through variables and mixins, reduces time through features like nesting. To use SASS, a compiler like Ruby or Koala must be installed. SASS has two syntax options, .sass and .scss. Key features include variables, mixins, extends, functions, operators, directives and nested properties.
This document provides an introduction and overview of SASS (Syntactically Awesome Style Sheets), a CSS preprocessor. It highlights key SASS features like nesting, variables, math operations, mixins and imports that allow for more efficient, reusable and readable CSS code. The document also briefly explains how to install SASS using Ruby gems and use it to compile SCSS files into normal CSS.
What is Basic?
Basic was originally developed for client projects. Originally a stripped down version of the ZEN theme, basic has now become its own concept of a theme starter. Basic boasts a clean HTML structure with extensible CSS classes and ID's for unlimited theming possibilities as well as a top-down load order for improved SEO.
Basic's goal is to provide themers the building blocks needed to get their designs up and running quickly and simply.
What is SASS?
Sass is a meta-language on top of CSS that¡¯s used to describe the style of a document cleanly and structurally, with more power than flat CSS allows. Sass both provides a simpler, more elegant syntax for CSS and implements various features that are useful for creating manageable stylesheets.
What will I Learn?
We will guide you through using Basic with SASS and Compass to kick-start your next Drupal theming project and show you how easy it is to get started. We will also cover the syntax and file structure of using SASS and how to get your development environment up
The document provides an overview of Sass (Syntactically Awesome Style Sheets), a CSS preprocessor. It discusses features of Sass like variables, nesting, inheritance, mixins and more that make writing CSS easier. It also covers using Sass with Compass, an open source CSS authoring framework, and Gulp, an automation tool for tasks like minification, concatenation, image optimization, and deploying files via SSH. Finally, it briefly introduces GreenSock for advanced animation capabilities.
HTML5, CSS, JavaScript Style guide and coding conventionsKnoldus Inc.
?
Coding conventions are style guidelines for any programming language. As, we are growing ourselves rapidly in learning new technology, the need for learning of the coding standards and conventions for the same language also arises.
So, here let us try to learn some coding guidelines for few frontend languages.
The document discusses CSS pre-processing with SASS and LESS. It begins with an introduction and disclosure by the author. The agenda then covers what CSS preprocessors are, why they are used, possible issues, how they work with basic examples, a comparison of SASS and LESS, and whether preprocessors should be tried. SASS is argued to be more robust with features like conditional statements, loop statements, and the Compass toolkit, making it a better choice than LESS overall.
Compass, Sass, and the Enlightened CSS DeveloperWynn Netherland
?
This document discusses Sass, Compass, and the enlightened web. It describes how Sass provides powerful features like variables, nested rules, mixins, selector inheritance and functions that allow developers to write more maintainable CSS. Compass is a library of Sass extensions that provides CSS3 mixins. Together, Sass and Compass allow developers to write stylesheets in a more simplified and structured way.
Sass is an extension of CSS3 that adds power and elegance to the basic language. It allows you to use variables, nested rules, mixins, inline imports, and more, all with a fully CSS-compatible syntax. (With a little help from Ruby) This talk will cover an overview of what Sass is, how to get it, run it, and use it, and show some examples of its magic.
Code examples at: https://github.com/founddrama/vt-code-camp
Elegant CSS Design In Drupal: LESS vs SassMediacurrent
?
This document compares LESS and SASS, which are meta-languages that extend CSS to allow variables, mixins, and other features. LESS processes stylesheets with JavaScript, while SASS uses the Ruby programming language. Both aim to make CSS more modular and reusable. The document discusses how each works, their differences, who created them, how Drupal supports them with modules, and key concepts like variables, mixins, and functions. It recommends that SASS will likely power Drupal 8's styling and provides additional learning resources.
This is a presentation I gave on Sept. 25, 2012 for the Winnipeg PHP Group on some of the features in LESS I have started using in my own development environment.
This document discusses accelerated CSS techniques using tools like CSS frameworks, JavaScript, and CSS preprocessors. It introduces concepts like nested rules, variables, mixins, extends, imports, and powerful functions in CSS preprocessors that allow generating complex CSS from simpler code. CSS frameworks like Blueprint and modules for CSS3 properties are demonstrated. Image sprites are also mentioned briefly.
Sass and Less are CSS preprocessors that add features like variables, nesting, mixins, and inheritance to regular CSS. Sass was designed by Hampton Catlin and developed using SassScript, while Less was designed by Alexis Sellier and allows real-time compilation via Less.js. Both preprocessors provide mechanisms for variables, nesting, mixins, and more to make writing CSS more efficient.
Using different kind of tools to build big styles for websites. Problem with big CSS is that it gets heavy, hard to manage, convoluted. But fortunately there are ways to keep structured and manageable. In this presentation we introduce combination of Makefile, SASS, ImageMagick, and other tools.
Sass is a preprocessor scripting language that is compiled into CSS. It allows for nesting, variables, mixins, and other advanced features to help manage large CSS codebases. The document discusses how to install and use Sass via the command line as well as with GUI tools. Key Sass features covered include variables, nesting, parent selectors, combining selectors, imports, extends, and mixins.
Breaking Free from Bootstrap: Custom Responsive Grids with Sass SusyJames Steinbach
?
Instead of relying on heavy, pre-formatted, markup-intensive CSS frameworks for grids, we can use a Sass grid framework to write clean, maintainable, performant CSS grid layouts.
twitter.com/jdsteinbach
jamessteinbach.com
Bringing sexy back to CSS: SASS/SCSS, LESS and CompassClaudina Sarahe
?
ºÝºÝߣ from a presentation given at 2011 Design for Drupal in Boston about two popular CSS extensions and Compass with a focus on how they integrate in Drupal environment. The goal is to present and overview of Sass and LESS in order to drive front-end developers to abandon plain old CSS. Compass is talked about as the reason to use Sass over LESS.
This document summarizes Sass (Syntactically Awesome Style Sheets), which is a preprocessor scripting language that extends CSS by adding features like variables, nested rules, mixins, inheritance, and other utilities. It discusses Sass features such as variables, nesting, mixins, functions, conditionals, and more. It also covers Compass, a Sass extension library and framework, which provides additional features like sprites, gradients, and vendor prefixing. Finally, it provides instructions for installing and using Sass and Compass on different platforms.
The document discusses adaptive theming using Compass and Susy grid. It covers using SCSS for file structure, implementing a Susy grid, responsive images, abstract classes and mixins, and optimizing the site. Mobile-first development and responsive design principles are emphasized. Key aspects covered include fluid grids and media, SCSS file structure, using Susy grid mixins, responsive mixins, resetting columns, and bonus techniques like abstract classes and mixins.
Rob Walker from Papertrail takes us through his recent journey from regular CSS to SCSS. If you¡¯re thinking of making the switch yourself and just need a little push, this is the talk for you.
Sass & Compass is a presentation about Sass, a CSS preprocessor, and Compass, an extension of Sass. It discusses features of Sass like variables, nested rules, and mixins that add functionality to CSS. It also covers how to set up and use Compass, which provides CSS3 properties and helpers through Sass mixins. The presentation provides examples of how these Sass features compile to regular CSS.
The document discusses Haml and Sass, which are template languages used to generate HTML and CSS respectively. Haml uses indentation and special characters to structure markup concisely while Sass allows nesting, variables, and other features to simplify CSS authoring. The document provides examples of basic Haml and Sass syntax and recommends starting with individual templates, using the proper file extensions, and checking whitespace when errors occur.
SASS is an extension of CSS that adds powerful features like variables, mixins, functions and more. It allows reusability through variables and mixins, reduces time through features like nesting. To use SASS, a compiler like Ruby or Koala must be installed. SASS has two syntax options, .sass and .scss. Key features include variables, mixins, extends, functions, operators, directives and nested properties.
This document provides an introduction and overview of SASS (Syntactically Awesome Style Sheets), a CSS preprocessor. It highlights key SASS features like nesting, variables, math operations, mixins and imports that allow for more efficient, reusable and readable CSS code. The document also briefly explains how to install SASS using Ruby gems and use it to compile SCSS files into normal CSS.
What is Basic?
Basic was originally developed for client projects. Originally a stripped down version of the ZEN theme, basic has now become its own concept of a theme starter. Basic boasts a clean HTML structure with extensible CSS classes and ID's for unlimited theming possibilities as well as a top-down load order for improved SEO.
Basic's goal is to provide themers the building blocks needed to get their designs up and running quickly and simply.
What is SASS?
Sass is a meta-language on top of CSS that¡¯s used to describe the style of a document cleanly and structurally, with more power than flat CSS allows. Sass both provides a simpler, more elegant syntax for CSS and implements various features that are useful for creating manageable stylesheets.
What will I Learn?
We will guide you through using Basic with SASS and Compass to kick-start your next Drupal theming project and show you how easy it is to get started. We will also cover the syntax and file structure of using SASS and how to get your development environment up
The document provides an overview of Sass (Syntactically Awesome Style Sheets), a CSS preprocessor. It discusses features of Sass like variables, nesting, inheritance, mixins and more that make writing CSS easier. It also covers using Sass with Compass, an open source CSS authoring framework, and Gulp, an automation tool for tasks like minification, concatenation, image optimization, and deploying files via SSH. Finally, it briefly introduces GreenSock for advanced animation capabilities.
This document introduces Sass and Compass, which are CSS preprocessors. Sass extends CSS with features like nesting, variables, mixins and functions. Compass provides useful CSS3 mixins and utilities. Some key features covered include Sass syntax like nesting and variables, Compass features like CSS3 mixins and sprites, and how to install and use Sass and Compass.
SASS is a CSS preprocessor that extends CSS by allowing nested rules, variables, mixins, inheritance and more. It has advantages like uniform CSS, abstraction of common patterns with mixins and functions, and reuse of values with variables. The document discusses these features and provides examples of using variables, mixins and functions in SASS.
SASS/SCSS Preprocessor can be a great help to create and manage complex css structures. It boosts css with pro features like defining and executing Variables, Functions and Mixins.
This document summarizes and compares CSS preprocessor tools Sass and LESS. Both tools allow for variables, mixins, nested rules and other features to aid in writing CSS in a more modular way. Sass uses the SCSS syntax which is a CSS superset, while LESS uses its own syntax. Both compile to plain CSS. The Compass framework is also mentioned, which builds on Sass and provides reusable components and a workflow for building CSS.
I'm excited to announce that I've just released the stable version of Sass 3.5. This release focuses on compatibility with new CSS syntax, and helps lay the groundwork for the upcoming module system and compatibility with Dart Sass.
Raleigh Web Design Meetup Group - Sass PresentationDaniel Yuschick
?
This document provides an overview of key features and capabilities of Sass (Syntactically Awesome Style Sheets), a CSS preprocessor. It discusses getting started with Sass, including installation and basic usage. It also summarizes various Sass features such as variables, nesting, mixins, functions, and loops that allow for more efficient and reusable CSS coding. The document serves as a helpful introduction to the power and flexibility of using Sass to generate CSS.
This document discusses CSS preprocessors and focuses on Sass. It explains that CSS preprocessors allow for reusable, scalable, and smart CSS through features like variables, nesting, mixins, and imports. Sass is a popular preprocessor that has two syntaxes - SCSS which uses CSS syntax and Sass which uses indentation. Sass compiles preprocessed code into normal CSS files and offers powerful features to avoid repetition and make CSS more maintainable.
This document discusses CSS preprocessors and focuses on Sass. It explains that CSS preprocessors allow for reusable, scalable, and smart CSS through features like variables, nesting, mixins, and imports. Sass is a popular preprocessor that has two syntaxes, SCSS and Sass, that add power and elegance to CSS. The document provides examples of how Sass features like variables, nesting, operations, mixins, and inheritance can be used to make CSS more manageable. It also covers installing Sass, converting Sass files to CSS, using partials and imports, and recommends additional resources.
Dallas Drupal Days 2012 - Introduction to less sass-compassc l
?
This document provides an introduction to Less, Sass, and Compass, which are CSS preprocessors. It discusses prerequisites including a strong understanding of CSS and familiarity with control structures and variables. The goals are to understand the high-level purpose of preprocessing languages and learn how to get started using them. Methods for using Less, Sass, and Compass with Drupal are presented, including modules and command line tools. Key concepts demonstrated include variables, mixins, importing, and frameworks like Compass. The document encourages questions and provides additional learning resources.
Presentation of LESS, a css preprocessor.
If you want to download PDF but don't want to login ºÝºÝߣShare,
go to Speacker Deck on which is the same downloadable PDF :
https://speakerdeck.com/katsunoritanaka/less-the-dynamic-stylesheet-language
The document discusses various new elements in CSS3 including shadow effects, rounded corners, border images, colored borders, opacity transitions, RGBA/HSLA colors, attribute selectors, multi-column layouts, transitions, web fonts, and media queries. It also covers CSS preprocessors like Sass and Less, adding variables, nesting, mixins and other features to make CSS more powerful and modular. Best practices for performance include minimizing HTTP requests, caching, browser support, frameworks and tools.
SCSS is a an extension of CSS that adds power and elegance to the basic language.
It helps keep large stylesheets well organized and get small stylesheets up and running quickly.
This recipe provides a structured approach for using SCSS Pre-processor for your web applications.
Features covered :
? Pre-processing
? Variables
? Nesting
? Partials
? Imports
? Mixins
? Inheritance
? Operators
This document summarizes a technical session on Syntactically Awesome Stylesheets (Sass). The session objectives are to introduce Sass and its advantages over regular CSS, demonstrate its features like variables, nesting, mixins and extends, and how to use Sass with Compass. The document provides examples of Sass code and the corresponding CSS output for these features. It also explains how to install Sass via command line or applications and set up a Compass project.
This document discusses concepts related to Sass (Syntactically Awesome Style Sheets), which is a CSS preprocessor. It describes how Sass allows for variables, nesting, mixins and other features to make CSS more powerful and maintainable. Key concepts covered include using variables to reduce repetition, creating reusable code with mixins, and how Sass files are compiled into normal CSS that browsers can understand.
SASS (Syntactically Awesome StyleSheets) is a CSS pre-processor that allows for nested rules, variables, mixins and more to extend the functionality of CSS. It compiles into regular CSS. Key features include nesting rules to reduce repetition, using variables to define common values for reuse, and creating mixins for commonly used CSS patterns or properties. SASS also allows for logic and functions. COMPASS is an open-source framework built on SASS that provides pre-made mixins and modules for common CSS patterns to simplify development.
Save 10% off any FITC upcoming event with discount code 'slideshare'. Details at www.fitc.ca
OVERVIEW
Think CSS isn¡¯t important? Or just for girls? Or an afterthought like accessibility or security? Spoiler alert: you¡¯re wrong (about all of those)! CSS has become the gateway drug for most novices and designers-turned-programmer; with preprocessors like LESS and SASS making it easier and easier for web developers to get further down the rabbit hole. In this talk, Kacey will cover a brief history of CSS and where it stands today, the difference between and how to use preprocessors, and where we can likely expect CSS to go in the future. If you¡¯ve ever wondered why UX developers love LESS/SASS, why preprocessors are essential in todays tech stack, then this talk is for you!
OBJECTIVE
Attempt to explain/dismystify CSS as it stands today
TARGET AUDIENCE
Anyone working in, or interested in, web development
ASSUMED AUDIENCE KNOWLEDGE
Little to no web development knowledge needed
FIVE THINGS AUDIENCE MEMBERS WILL LEARN
Why is CSS important
What preprocessors do
Some basic Sass mixins
How preprocessors make your life easier
How CSS is becoming more like JS
2. What is Sass?
¡°Sass is a meta-language on top of CSS that's used to describe
the style of a document cleanly and structurally, with more
power than flat CSS allows. Sass both provides a simpler, more
elegant syntax for CSS and implements various features that are
useful for creating manageable style sheets.¡±
- from http://sass-lang.com/
¡°Sass is an extension of CSS3, adding nested rules, Variables,
mixins, selector inheritance, and more. It¡¯s translated to well-
formatted, standard CSS using the command line tool or a web-
framework plugin.¡±
- from internet
3. a little history¡..
? Sass was first given life by Hampton Catlin in 2006, later
supported by Natalie weizembaum and chris eppstein
? Sass started life in ruby community
? Sass supports two syntaxes
¨C Indentation syntax with file ext .sass
¨C Css compatible syntax with file ext .SCSS
? Sass is free to use, require no license.
4. Why use it?
? Modularize (@import)
? Variables for maintainability
? Mixins improves reusability
? Reduces redundant rules (keep it DRY)
? Scalable and Maintainable
Make writing style more fun¡.
5. How do I install sass on my computer¡
? On Mac
just run ¡°gem install sass¡±
? On Window
download and install ruby (http://rubyinstaller.org/)
on cmd prompt - run
¡°gem install sass¡±
6. Data Types support by sass
? SassScript supports Seven data types
// number
example 10, 40, 50px, 60%
//string
example ¡°foo¡±, ¡°bar¡±, baz
//colors
example blue, #04a3f9, rgba(255,
0, 0, 0, 5)
//booleans
example true or false
//Null
example null
//list
example
$awesome-list: ¡°.bar¡± ¡°.foo¡±
¡°.odd¡±
//maps or hash
example
$alist: (error: red, warn: blue,
done: green)
7. Lets learn to read sass
? Variables
// sass syntax defining the variables
$red: #ff0b13
$blue-color: #091fff
p
color: $red
//scss syntax defining the variables
$red: #ff0b13;
$blue-color: #091fff;
p {
color: $red; }
8. Lets learn to read sass
?Nesting Rules
//sass syntax coloring the p
tag inside #id ¡°awesome¡±
$common-color: red
div#awesome
p
color: $common-color
a
color: blue
&:hover
color: yellow
//scss syntax defining the
variables
$common-color: red;
div#awesome {
p {
color: $common-color;
a {
color: blue;
&:hover{
color: yellow;
}
}
}
}
9. Lets learn to read sass
Module structure with @import
//sass syntax
// main.sass
@import navigation
@import morestyle
body
max-width: 1200px
margin: auto
// ¡°_morestyle.sass¡±
div
margin: auto
padding-top: 5px
//scss syntax
// main.scss
@import ¡°navigation¡±
@import ¡°morestyle¡±
*{
box-sizing: border-box;
}
body {
max-width: 1200px;
margin: auto;
}
// ¡°_morestyle.scss¡±
div{
margin: auto;
padding-top: 5px;
}
18. Lets learn to read sass
Programmatic Logic (@for loop in sass)
?//sass syntax
@for $i from 1 through 5
.div_#{$i}
color: red
@for $i from 6 through 10
.div_#{$i}
color: green
//scss syntax
@for $i from 1 through 5 {
.div_#{$i} {
color: red;
}
}
@for $i from 6 through 10 {
.div_#{$i} {
color: green;
}
}
21. how do you write sass
1. pick up a text editor (like atom or sublime¡ or
anything you like)
2. choose syntax style you want to follow (sass or
scss)
3. code your style rules and save the file as (.sass
or .scss) like so.
4 .then comes the compilation¡..
22. how to compile sass
? on cmd prompt type ¡°sass <filename>.sass¡± the
output will create new css file with
¡°<filename>.css¡± (please follow step above to
install sass on your mac or pc)
alternatively
? on cmd prompt type ¡°compass <filename>.scss¡±
the output will create new css file with
¡°<filename>.css¡±
23. how to compile sass
? as a option you can use ¡°compass watch¡± to
continuously watch for file changes and compile
them into css
24. So what next¡.
awesome you have learn about sass¡ next steps
? learn more complex topics (using compass)
? pick up a random css file re-code it into sass
? read awesome blogs from frontend
developers who works on sass and
coffeescript
? take same online course (if you can afford it)
¨C www.codeschool.com
¨C www.teamtreehouse.com (i like this
better)