How to get window width including scrollbars (if they exist)

Javascript and jQuery give different values for window.outerWidth vs $(window).outerWidth(). In this case, you want to use plain old Javascript. It will include the scrollbar(s) if they exist, as opposed to jQuery which ignores them.

Leave a Reply

Your email address will not be published. Required fields are marked *