Why use `*-device-width`

霸气de小男生 提交于 2019-12-11 22:53:19

问题


I dunno if its right to post a similar question to a previously closed one. Its quite different so I thought I'd try.

Ok, *-device-width is to target devices (not rendering area) with a specific width. *-width is to target the rendering width. So when designing, won't I always want to target based on rendering area, if the device width is say 768 but the browser chrome (for example) takes up 20px of that, then won't scroll bars appear if I use *-device-width. So question is shouldn't I use *-width every time?

Suppose next time, tablets allow users to resize their browsers, wont my site be "unresponsive" if I use *-device-width?


回答1:


You shall find a decent explanation at this link. Scroll down to about the middle of the page.



来源:https://stackoverflow.com/questions/8305409/why-use-device-width

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!