Boemska / h54s

Boemska HTML5 Data Adapter for SAS
https://boemskats.com
Other
48 stars 22 forks source link

ES5 Compatibility + IE11 support #103

Closed cj13579 closed 4 years ago

cj13579 commented 4 years ago

Note: This PR closes #97

What is this?

The recent 2.0 release of h54s broke compatibility with older Microsoft browsers which use ECMAScript 2015 (ES5). This change ensures that an ES5 compliant version of the adapter is compiled during the build process.

Specifically, we've added new Babel components that perform the trans-piling between the two ECMAScript versions (the other being ECMAScript 2016) and we've added a new IE Polyfill to overcome a compatibility issue that was discovered.

Why?

Many Enterprises still have restricted access to browsers like Chrome and Firefox and some just prefer IE. Its important that the h54s adapter is able to support the development of Enterprise applications that prefer to use older Microsoft browsers.

Testing

I've picked the two Windows platforms which I suspect that the vast majority of people using IE browsers will be using. As well as the integration tests, for each of these browser types I tested the following:

The results of the testing was as follows:

Platform IE11 IE10 IE9 IE8
Windows 10 N/A N/A N/A
Windows 7

Other info

While this change adds support for older Microsoft browsers (IE11 and IE10) during testing I did run into errors on even older browsers like IE9 and IE8. Considering both IE9 and IE8 have long since been deprecated (and even IE10 is now deprecated) I don't see supporting these browsers as a priority nor a significant problem.

Ices-Eyes commented 4 years ago

Ehm...dumb question, i'm really sorry about this... How do you use this? If I include the normal h54s.min.js it still not work in IE. If I include the min file in es5 subfolder it works. But then, how do you conditional include the two file, since conditional comments work just till IE9?

boomskats commented 4 years ago

You should just be able to use the one in the es5 subfolder and that's it, it should be forward compatible & the polyfills should only be applied for IE.

Does the new es5 version not work in more modern browsers, does it break stuff?

Ices-Eyes commented 4 years ago

Nope, as far as what I've tested, it worked good, so will go with just the es5 one. The presence of the two files had made me think there would be a version specific for older and one for newer browsers :)

cj13579 commented 4 years ago

Awesome, glad you got it working. Its a good point you raise though, that will probably confuse others. I will look at how we can update the documentation to make that a little clearer.

Ices-Eyes commented 4 years ago

that will probably confuse others.

Thanks to let me feel e little less dumb :satisfied: