You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've been playing around with your ES6 UI5 app sample and got stuck at when I tried to include polyfills so that such an app should be shipped to browsers like ie11.
I started by adding the according dependency...
npm install --save @babel/polyfill
The babel config that I used for the builder Transpile task looks like this:
However, this causes the polyfill imports to be added to the top of the js files as require calls, such as this, which can not be understood by the browser.
But even if the polyfills would be imported as AMD modules, I wonder if those files would be available in a build result and be respected by a ui5 self-contained build?
I'm wondering if you could give any insights and information on how such an extended setup of your sample project could look like?
The text was updated successfully, but these errors were encountered:
the UI5 self-contained build doesn't consider Common JS require calls in the scripts. They must be either added to the sap.ui.define and available as modules or another tool needs to ensure to append the content of those files in front of the modules.
In general, your question is really interesting and if I find some time the next days I would really like to look into your requirement and see how to solve this together with Babel and the UI5 tooling.
thanks for your fast response. Regarding the CommonJS require syntax, I was aware that this is probably not going to work with the tooling, yet hadn't found a way to force Babbel to add polyfills using AMD syntax.
Cool, its been really exciting to explore the new capabilities of the evolutionized UI5 in conjugation with the ui5-tooling, keep up the good work 👍
Hi Peter,
I've been playing around with your ES6 UI5 app sample and got stuck at when I tried to include polyfills so that such an app should be shipped to browsers like ie11.
I started by adding the according dependency...
The babel config that I used for the builder
Transpile
task looks like this:However, this causes the polyfill imports to be added to the top of the js files as require calls, such as this, which can not be understood by the browser.
But even if the polyfills would be imported as AMD modules, I wonder if those files would be available in a build result and be respected by a ui5 self-contained build?
I'm wondering if you could give any insights and information on how such an extended setup of your sample project could look like?
The text was updated successfully, but these errors were encountered: