Disable Negative Padding for Internet Explorer 11

Sample L

Works only with Internet Explorer

This sample prevent "padding-left" from becoming a negative value when window.Innerwidth < 704px.

Sample R

Works only with Internet Explorer

This sample prevent "padding-right" from becoming a negative value when window.Innerwidth < 704px.

Usage

Import

<script src="disableNegativePadding.js"></script>

or

require("disableNegativePadding");

Instantiation

var $target = document.querySelector('.target');
new disableNegativePadding($target);