Sublime text 3 Installing and using PX conversion to REM plug-in

Source: Internet
Author: User
Tags sublime text

REM This unit for mobile is relatively strong, so here to introduce sublime text 3 to the PX conversion to REM plug-in installation and use, as long as the plug-in installed, input how many px,sublime will prompt the corresponding REM value, you do not have to calculate the!!

1. First at this address:https://github.com/hyb628/cssrem.git Download Plugin

2. Unzip the downloaded plugin and open Sublime, find:Sublime Text, Preferences, Browse Packages, put the extracted folder into the open file

3. This time the plug-in is installed, and then enter a CSS in the value we want, there will be a corresponding hint:

Automatic conversion after Enter:

4. Here the 40 is the default reference value of the plugin, we can change according to our own needs:

set in Cssrem->settings-user, Package Settings, Sublime Text, Preferences, enter the following parameter configuration, You can modify the number of base numbers and converted decimals:

{
"Px_to_rem": the unit ratio of//PX to REM, default to 40
"Max_rem_fraction_length": 6,//px to the maximum length of the number of parts of REM. The default is 6.
"Available_file_types": [". css", ". Less", ". Sass", ". html"]
Enable the file type for this plug-in. The default is: [". css", ". Less", ". Sass"]
}


The base number is changed after the modification:

Note: The parameter profile is not written by default, it is the default setting! Edit the corresponding content input can!!

Sublime text 3 Installing and using PX conversion to REM plug-in

Related Article

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.