I'm working on a data table with a scrollable body and sortable, static headers, and when the vertical scrollbar appears, it messes with the right alignment between the header tags and the td tags below it.
Without questioning the HTML behind the table... Is there a way, using LESS, to calculate the width of the scrollbar in the scrollable element, so that I can assign it to a variable to use as padding in the row of headers above it? For example, in my Google chrome browser right now, padding the right of my header div with 18px fixes things, but I want this compatible across IE10+ and all other browsers.
If no other way, a vanilla JS ECMASCRIPT 6 method is preferred. I am not using jQuery in this application.