Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

A pixel is defined as 1/96th of an inch in the web world so it is dependent on your dpi/scaling. There is a window.devicePixelRatio that JavaScript can use to get actual pixels.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: