Closed dfang closed 10 years ago
I use iPhone to visit responsejs.com/labs/dimensions/, but why window.screen.width is 320 instead of 640, and window.screen.height is 480 instead of 960 ?
window.screen.width
window.screen.height
who can explain this ?
thanks !
@dfang 320 is correct because 2 === window.devicePixelRatio on the iPhone. Test the media query.
2 === window.devicePixelRatio
I use iPhone to visit responsejs.com/labs/dimensions/, but why
window.screen.width
is 320 instead of 640, andwindow.screen.height
is 480 instead of 960 ?who can explain this ?
thanks !