Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

移动端适配rem转换问题 #28

Closed
CJ-king opened this issue Jul 6, 2018 · 1 comment
Closed

移动端适配rem转换问题 #28

CJ-king opened this issue Jul 6, 2018 · 1 comment

Comments

@CJ-king
Copy link

CJ-king commented Jul 6, 2018

目前组件在mip2 build过程中样式中的px并没有转换成rem,是否可以统一下转换规则,然后在打包过程中把这个功能添加上?

@PengXing PengXing added help wanted Extra attention is needed enhancement New feature or request feature request and removed help wanted Extra attention is needed enhancement New feature or request labels Jul 9, 2018
@PengXing
Copy link
Contributor

我觉得 px 是有它的使用场景的,而且应该很多,相反,rem 的使用场景反而没有 px 多,那为什么要将 px 都转成 rem 呢?

现在我们提供的 rem 方案是

  1. width 大于 360px 的时候,1rem = 100px
  2. width 小于等于 360px 的时候,1rem = 90px

在这个方案中,rem 需要开发者自己根据上面这两个规则来计算

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants