Errors in Sass compilation and Compass Compilation
Some time ago, when I used Compass, I encountered a difficult problem. Now I have recorded my blog to help you.I. Problems:
When using Koala or gulp for compilation, the following error is prompted:
Ii. Solution
From the question point of view, the prompt is not found. A folder under the sass-cache folder (the parent directory name contains special char
This is a memorandum of understanding.1. Number
type-of(0) // numbertype-of(1px) // number2. String
type-of(a) // stringtype-of("a") // string3. bool
type-of(true) // booltype-of(04. Color
type-of(rgba(1,2,3,.3)) // colortype-of(rgb(1,2,3)) // colortype-of(#fff) // colortype-of(red) // color5. List (SASS. List = Js.
First, prefacePrior to understanding the use of okhttp cache, and the use of the cache is a preliminary summary of 80650856. The cache is primarily intended to obtain resource information directly from the cache in the absence of a network, or when resources do not need to be updated in real time to the backend. On the one hand, it can still give the user a good interface in the case of disconnection, and another aspect is to avoid the pressure on the backend by the frequent request network. At
Parameters The party must look, preliminary understand the charm Blue Max and the Phantom Blue E Hardware Specification parameter contrast situation, details below.
Charm Blue E and the charm Blue Max parameter contrast
Contrast model
Charm Blue E
Charm Blue Max
Screen specifications
5.5-inch 1920*1080
Introduction: WEB front-end HTML pages and CSS files can sometimes be cumbersome to write, but with tools that help us easily build pages. Sass is a CSS development tool, with the corresponding syntax, you can have logic and concise writing CSS code. This article describes the main is based on Dreamever CS5 plus Emmet plug-ins to quickly write concise HTML pages.
1. Ruby Installation and ConfigurationRuby can be found in Baidu search Baidu Softwar
Download and install sass and compass in ruby, and reference css styles.
It is very convenient to use scss to write css. The first is ruby download and installation, is the http://rubyinstaller.org/downloads. After the download, open the installation file and click Next to install it. Note that
Check the following to prevent future commands from being found.After the installation is complete, click it to open it.Run the gem install
CSS efficient development practices: CSS 3, LESS, SASS, Bootstrap, Foundation-Reading Notes (1) set the background image
In addition to computer access to the Internet, tablets, smartphones, Smart TVs, and other devices can access the Internet. In the multi-device era, building a multi-screen experience is not as difficult as we have heard. But does this increase the difficulty of learning CSS? I don't know how to get started. I only know a little bas
My environment: Win7-64bit WEBSTORM9Webstorm Installing the Sass PluginTo have Webstorm automatically compile the sass file:Open the Settings window->file watchers-> to the right of the green plus->scssClick OK to finish compiling the Scss file.Further configuration 1:Always generate CSS and Css.map filesIn ' Arguments ':--no-cache--update $FileName $: Add--sourcemap--watch $FileNameWithoutExtension $.cssi.
Koala download sass Compile as CSS fileRequirejs Why use1, effective to prevent naming conflicts2. Declare the dependencies between different JS files3. Let our code be organized in a modular wayRequirejs Common methods1. Requirejs.config Definition AliasesMain.js Portal File (files that are called immediately after the Require.js file is loaded in the. html is the entrance file in Data-main way)reuirejs.config ({ paths:{ jquery:'
Two SCSs formats
Sass braces
SCSs CSS writing
Arguments: -- no-Cache-style compressed -- Update $ filename $: CSS/$filenamewithoutextension}.css
The marked part is the output CSS type and the additional output path, that is, whether the output CSS is compressed or not, and then the project directory creates a CSS folder to put it inside.
-- Style
Nested: Nested indent CSS code
Expanded: CSS code without indent Extension
Compact: Concise CS
Mixed macros are primarily used to pass parameters, but when Sass compiles the same mixed macro, the same styles are not merged. Generates redundant code.Inheritance is primarily used where arguments are not passed, and the base class already exists, and the same style is merged after compilation, not enough: the declared base class generates code regardless of whether the base class is called.Placeholders are similar to inheritance, but placeholders
1. Set up a configuration file after Sass and compass are installed2. Add a Sprite folder to hold the pictures that will be merged, such as the color folder[email protected] The command Reference. when Compass sees the @import parameter for the instruction *.png , it assumes that all the pictures under this directory are .png made into a sprite.You can also use certain rules to make it according to the picture and layout you need to generate the corre
A better name for the variable
Variables are one of the simplest features in sass, but sometimes they can be used improperly. Creating a site-wide, semantically variable is an essential task. If the name is not good, he will become difficult to understand and re-use.Here are some tips for naming variables that provide references:
Don't be vague when naming variables
Stick to a naming convention (Modular, BEM, etc.)
It makes sense
SASS writing skills
Better Name Variables
Variables are one of the simplest features of Sass, but sometimes they are not used properly. Semantic variables within the scope of site creation are indispensable. If the name is not good, it will become hard to understand and reuse.
Here are some tips for naming variables for reference:
Do not be vague when naming Variables
Stick to a naming rule (Modular,
Now the most common three CSS preprocessor frameworks are Sass, less CSS, and Stylus.For less, you can use the less file directly on the page, but you can refer to Less.js for parsing, and the less output as a CSS file. It is recommended to use the latter.The most commonly used less compiled output CSS tool: NPM associated with node. js, installing the less module and then using less test.less>test.css for output.Reference:Http://www.cnblogs.com/shaom
What is CsscombThe official website has only one sentence description:
Makes your code beautiful (make your codes more beautiful)
The popular point says:
Csscomb is used to typeset CSS code ... Can be said to be a format plug-in, relying on Nodejs
get csscomb– This isn't the topic of today.Official website: Csscomb
Supports many editors, such as sublime/atom/brackets, etc.
Third party csscomb-This is the topic of today.Yesterday wrote a CSS3 article ...
is my big gfw mighty, can change the source to x Treasure of the server to solve:$ gem sources-l$ gem sources--remove https://rubygems.org/$ gem sources-a http://ruby.taobao.org/$ gem sources-l//Then I just updated the ruby version $ sudo gem update--systemAfter the above toss, smooth installation sassCommon syntax variablesDefine $magin:30px; Px$blue: #1875e7; Color$side:left; Str usage:boder-#{$side}-radiusAll variables of the numeric type can be calculated accordingly.NestingNav { ul {...
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.