Using WebJars

If your browser components make use of Javascript libraries, WebJars provide a good way of managing the library dependencies. To use WebJars:

  1. Download the WebJars you want to use.

  2. Deploy the downloaded files to http://content-engine-domain/webservice-extensions/WEB-INF/lib.

The contents of the META-INF/resources/webjars/ folders in the WebJars you deploy will then be made available to your components at http://content-engine-domain/webservice-extensions/webjars/.

If, for example, you deploy a JQuery WebJar to http://content-engine-domain/webservice-extensions/WEB-INF/lib, then the following files will be made available to your Javascript code:

http://content-engine-domain/webservice-extensions/webjars/jquery/version/jquery.js
http://content-engine-domain/webservice-extensions/webjars/jquery/version/jquery.min.js
http://content-engine-domain/webservice-extensions/webjars/jquery/version/jquery.min.map
http://content-engine-domain/webservice-extensions/webjars/jquery/version/webjars-requirejs.js