Home >Web Front-end >HTML Tutorial >样式单位之px、em、rem_html/css_WEB-ITnose

样式单位之px、em、rem_html/css_WEB-ITnose

WBOY
WBOYOriginal
2016-06-24 11:36:371000browse

  最近在看bootstrap.css的时候看到很多单位都用到rem而不是熟系的px。经学习得知:

1、px精确的单位;

2、em为相对单位(相对父级元素)

3、rem为相对单位(相对根元素 html)

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