I am trying to figure out how to achieve compression and minification for all my js files. Currently i have them in a hook plugin under /html/js/mycustomjs/
folder.
I understand that liferay has its own mechanism to compress javascripts, in barebone.jsp or everything.jsp, and found the list of files declared in the javascript.barebone.files
and javascript.everything.files
properties on portal.properties
.
The question is, can i use this mechanism to compress js files of my own ? should i override such properties in the portal-ext.properties
? Or should i just use the MinifierFilter
by myself ?
Moreover, is a hook plugin the right place to put js files that i want available on all of the portal's sites?