O'Reilly logo

Learning Ext JS 4 by Armando Gonzalez, Crysfel Villa

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Variables

The new way to create themes is just awesome. There are a lot of variables that we can change to customize our theme, variables for colors, fonts, margins, borders, and many more things.

In Compass we can define variables using the dollar ($) sign. Every time we find a word that starts with the dollar sign it means that it's a variable that we can read or assign a value. The following lines of code are some examples of variables:

$background-color: #f3f3f3;
$font-size: 1.5em;
$header-height: 45px;
$custom-text: 'This is a text value';

As shown in the previous code we can assign a value using the colon (:), we can also use colors, sizes, or texts as values. We need to use a semicolon(;) every time we end a statement.

By default, Ext has defined ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required