body, html {
position:absolute;
width:100%;
height:100%;
margin: 0;
padding: 0;
overflow: hidden;
}
When using window.innerWidth
, there is a discrepancy between the values returned by Firefox and Chrome. Firefox returns 1429 while Chrome returns 1159. Can someone explain why this difference occurs and provide a solution to fix it? Thank you.