Hello.
After updating from AEM 6.5.11 to AEM 6.5.17, some of our Clientlibs for dialogue extensions are no longer working. The cause appears to be that we have ES6 code, which has run flawlessly in browsers so far, but seems to be transformed into ES5 after the update. Unfortunately, the result is not fully functional. As we do not want to rewrite the working ES6 code - how can I turn off this preprocessor?
Thank you.
Solved! Go to Solution.
Views
Replies
Total Likes
Hi @IS24Tom ,
In AEM 6.5, the JavaScript files are transpiled from ES6 to ES5 using a preprocessor called Babel by default. This is done to ensure compatibility with older browsers that may not support ES6 syntax. If you want to disable this preprocessor and use your ES6 code directly without transformation, you can follow below steps:
Inside the definition file, look for the jsProcessor
property. It is set to default
by default, which indicates that Babel is used for transpiling.
Change the value of the jsProcessor
property to none
. This disables the preprocessor and prevents the ES6 to ES5 transformation.
Views
Replies
Total Likes
Hi @IS24Tom ,
In AEM 6.5, the JavaScript files are transpiled from ES6 to ES5 using a preprocessor called Babel by default. This is done to ensure compatibility with older browsers that may not support ES6 syntax. If you want to disable this preprocessor and use your ES6 code directly without transformation, you can follow below steps:
Inside the definition file, look for the jsProcessor
property. It is set to default
by default, which indicates that Babel is used for transpiling.
Change the value of the jsProcessor
property to none
. This disables the preprocessor and prevents the ES6 to ES5 transformation.
Views
Replies
Total Likes
I had already tried that. However, without success. Moreover, this came with the last update from 6.5.11 to 6.5.17.
Views
Replies
Total Likes
I probably don't know something, because I changed
categories="[cq.authoring.dialog]"
to
categories="[cq.authoring.dialog.all]"
it works. Is there some magic behind the dialog categories, that I should know?
Views
Replies
Total Likes
It is strange ,because the cq.authoring.dialog
category is a default category that is commonly used for dialog fields that are intended for authoring purpose. But using categories="[cq.authoring.dialog.all]"
, you are including all available dialog field types in the category selection for your dialog. This allows you to have access to a wider range of field types when configuring your dialog.
Views
Replies
Total Likes
Hi @IS24Tom ,
You can override the default aem minification by adding following property in ClientLibraryFolder:
jsProcessor="[default:none,min:none]"
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies