What are css3, less, sass

青灯夜游
Release: 2022-03-17 18:34:40
Original
1809 people have browsed it

css3 is an upgraded version of CSS technology, a computer language used to express file styles such as HTML or XML; Less is a CSS extension and dynamic style sheet language, and a CSS preprocessor; Sass is a CSS preprocessing language written in Ruby that can be used to describe file styles clearly and structurally.

What are css3, less, sass

The operating environment of this tutorial: windows7 system, CSS3&&Sass3.7.4 version, Dell G3 computer.

What is CSS3?

CSS is the abbreviation of Cascading Style Sheets. It is an application used to express HTML (Standard Generalized Markup Language) or XML (Standard Generalized Markup Language). a subset) and other file-style computer languages.

CSS can perform pixel-level precise control over the layout of element positions in web pages, supports almost all font size styles, and has the ability to edit web page objects and model styles.

CSS3 is an upgraded version of CSS (Cascading Style Sheets) technology. It was formulated in 1999. On May 23, 2001, W3C completed the working draft of CSS3, which mainly includes box model, list module and hyperlink method. , language module, background and border, text effects, multi-column layout and other modules.

One of the major changes in the evolution of CSS is the W3C's decision to break CSS3 into a series of modules. Browser vendors innovate quickly at the pace of CSS, so by taking a modular approach, elements in the CSS3 specification can move forward at different speeds because different browser vendors only support given features. But different browsers support different features at different times, which also complicates cross-browser development.

The principle of CSS3 is the same as that of CSS. It is to customize the selectors of the style sheet in the web page, and then reference these selectors in large numbers in the web page.

New features

There are many new features of CSS3, such as rounded corners, graphical borders, block shadows and text shadows, using RGBA to achieve transparency effects, gradients Effects, use @Font-Face to achieve customized fonts, multiple background images, text or image deformation processing (rotation, scaling, tilting, movement), multi-column layout, media queries, etc.

What is Less?

Less is a CSS extension and dynamic style sheet language, a CSS preprocessor that can run on the client or server side, helping us customize, manage and reuse the style of web pages surface.

Less is an open source language that is also cross-browser compatible.

Advantages:

1. Less is a CSS preprocessor. After compilation, it generates simple CSS, suitable for browsers.

2. Less supports cross-browser compatibility.

3. Since Less uses nesting, the code is shorter, cleaner, and organized in a specific way.

4. Since Less uses variables, maintenance can be achieved faster.

5. Less provides a series of operators to make coding faster and more time-saving.

6. Less provides @mport rules so that we can easily process external files. NOTE: Importing is required because many people split their stylesheet into multiple files instead of putting it into one file.

7. Less provides merge attributes. The most exciting feature of Less is accepting multiple values such as transform, transition and box-shadow.

8. Less is written in JavaScript, which can compile faster than other preprocessors for CSS.

Disadvantages:

1. If we are not familiar with CSS preprocessing, we must spend some time learning the relevant knowledge of Less.

2. Compared with older preprocessors such as SASS which include frameworks such as Compass, Gravity and Susy, Less provides fewer frameworks.

3. In Less, there is tight coupling between modules, so reusing and/or testing related modules requires more effort.

What is sass?

Sass is a meta-language higher than CSS. It can be used to describe file styles clearly and structurally, and has more powerful functions than ordinary CSS. Sass provides a cleaner, more elegant syntax while providing a variety of features to create maintainable and manageable stylesheets.

Sass is a CSS preprocessing language written in Ruby language. It was born in 2007 and is the largest mature CSS preprocessing language. It was originally designed to work with HAML (an indented HTML precompiler), so it has the same indentation style as HTML. SASS is an extension of CSS3 that adds rule nesting, variables, mixins, selector inheritance, and more. Convert it into standard, well-formed CSS code by using command line tools or WEB framework plug-ins.

(Learning video sharing:css video tutorial,web front-end)

The above is the detailed content of What are css3, less, sass. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!