May 27, 2020
Estimated Post Reading Time ~

Clientlibs specific Preprocessors minification in AEM

AEM 6.4/ AEM 6.5 Clientlib specific Preprocessors
AEM allows for pluggable preprocessors and ships with support for YUI Compressor for CSS and JavaScript and Google Closure Compiler (GCC) for JavaScript with YUI set as AEM's default preprocessor.

By default, AEM uses the YUI Compressor. Switching to the GCC compressor for particular clientlibs may solve some issues observed when using YUI.

You can choose to configure the preprocessors configuration per client library or system-wide.

Add the multivalue properties cssProcessor and jsProcessor on the clientlibrary node
Or define the system default configuration via the HTML Library Manager OSGi configuration

A preprocessor configuration on the clientlib node takes precedence over the OSGI configuration.

cssProcessor: ["default:none", "min:yui"]
jsProcessor: ["default:none", "min:gcc;compilationLevel=advanced"]

Adobe Documentation link click here


By aem4beginner

No comments:

Post a Comment

If you have any doubts or questions, please let us know.