<script type="text/javascript">
(function() {
var html = document.documentElement;
var hWidth = html.getBoundingClientRect().width;
html.style.fontSize = hWidth / 36 + 'px'; // 36可更改
console.log(html.style.fontSize);
})();
</script>
rem布局代码
最新推荐文章于 2022-12-21 18:49:47 发布