User Settings->Extensions" and find "px to rem"; finally press the shortcut key "ALt+Z ” can be changed to “rem”."/> User Settings->Extensions" and find "px to rem"; finally press the shortcut key "ALt+Z ” can be changed to “rem”.">

Home >Development Tools >VSCode >How to change rem in vscode

How to change rem in vscode

藏色散人
藏色散人Original
2019-12-18 11:39:084769browse

How to change rem in vscode

How to change rem in vscode?

When developing h5 pages, we need to use rem units, so how to convert px to rem in vscode?

Related recommendations: vscode tutorial

Here I chose the px to rem plug-in. The steps to use:

First install the px to rem plug-in;

Then find **px to rem **

How to change rem in vscode

in Settings->User Settings->Extensions or directly in setting.json Configuration:

    "px-to-rem.px-per-rem": 75,
    "px-to-rem.number-of-decimals-digits": 4,

Then edit width: 200px in the style file, press the shortcut key ALt Z to change to width: 2.6667rem;

Note:

I set it here The base value is 75, because the default design draft width is 750px;

For specific details, you can directly view the plug-in details.

The above is the detailed content of How to change rem in vscode. For more information, please follow other related articles on the PHP Chinese website!

Statement:
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