Picture of Markus Görlich
Is it possible to convert ES6 to ES5 for IE11 support?
by Markus Görlich - Thursday, 28 November 2019, 10:42 AM
 

Hello everyone,

I recently started using Adapt (Framework 2.4.0, Authoring 0.10.1) and created some extensions and components using ES6. I noticed that there is no conversion to ES5, so that my courses won’t work with IE11.

How would you proceed? Rewrite everything in ES5 or use something like Babel? Up until now, I used the Authoring Tool. But if there is a way to change the build process to convert ES6 to ES5, I’m happy to use the command line.

Basically, I’m looking for an easy way to still use ES6 and get an ES5-compatible course as output.

Thanks,
Markus

Picture of Matt Leathes
Re: Is it possible to convert ES6 to ES5 for IE11 support?
by Matt Leathes - Thursday, 28 November 2019, 11:53 AM
 

Hi Markus

As things stand, the easiest way forward will probably be to convert your extensions and components to ES5. Also note you can't even use the few bits of ES6 that IE11 does have support for (which is just let and const I think) as the JS minification library we're using at the moment doesn't seem to be able to cope with these...

The intention for the next major release of the Framework (v6, sometime in 2020) is to restructure Adapt so as to allow for the use of transpilers like Babel or TypeScript.

The Adapt OS project was started back in 2013 when the web development landscape was very different indeed and a lot of what is considered standard these days was only in its infancy back then! The ES6 spec wouldn't be finalized for a couple of years, React had only just been released (and was pretty much unheard-of) and IE6 and 7 were still very commonly-used - in fact it was a difficult decision to say that we weren't ever going to support those two browsers, one I'm very glad we held firm on!