jonathantneal / flexibility

A JavaScript polyfill for Flexbox

Home Page:https://jonathantneal.github.io/flexibility/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Crashes (currentStyle: object is null or undefined) on IE9 if there is a hidden child element

corgrath opened this issue · comments

IE9 crashes with follow error message

The browser is Swedish, so the error message is also in Swedish, but it says the currentStyle: object is null or undefined.

SCRIPT5007: Det går inte att hämta värdet för egenskapen currentStyle: objektet är null eller odefinierat 
flexibility2.js?_rtv=033839933, rad 1 tecken 13792

A simple test case for this is:

.christoffer-flex {
    -js-display: flex;
}
.christoffer-hide {
    display: none;
}

<div class="christoffer-flex">
    <div class="christoffer-hide">hello world</div>
</div>

Also getting the same error

SCRIPT5007: Unable to get value of the property 'currentStyle': object is null or undefined 
flexibility.generated.js line 9 character 13792

It will fix after #52

These errors and the ones related to SVGs will be resolved in the next release. They cannot access the current style of the element, so they are failing. I am now working on this.