Do you avoid using "inherit" value of style.display?

Updated by Brady Stroud [SSW] 1 year ago. See history

123
<introEmbed body={<> The property value “inherit” of style.display is not recognized by IE7 and IE7 compatibility mode. So if you use this value in Javascript, it will cause script error in IE7 and IE7 compatibility like: "Message: Could not get the display property. Invalid argument." So to make your Javascript and CSS style more compatible and avoid using "inherit" value of style.display: </>} />
divLoading.style.display = "inherit";

❌ Figure: Bad code - inherit property.

divLoading.style.display = "block";

✅ Figure: Good code - block property.

Acknowledgements

Related rules

Need help?

SSW Consulting has over 30 years of experience developing awesome software solutions.

We open source.Loving SSW Rules? Star us on GitHub. Star