Hi,
I want to export my demo solution in NG client to a war file.
At the last step I get an error saying “Could not group and minify JS and CSS resources”
This must have to do something with my custom web components since other solutions not referring to this component package export fine.
Any suggestions?
Thanks
Hi Rob,
please create a case in our support system for the issue.
In the meantime if you identify which package is preventing you from grouping you can explicitly tell Servoy not to group it’s library dependency by adding “group”:false in the .spec
example
"libraries": [{"name":"font-awesome.css", "version":"4.6.3", "url":"servoyextra/fontawesome/lib/font-awesome.min.css", "mimetype":"text/css", "group":false}],
Fixed,
In case you have more than one component you can always create a lib folder(at component’s folder for e.g check bootstrapextracomponents) and add reference to files in Manifest.mf to avoid this issue.Also this issue may occur if you have added js files into component itself i.e with spec and html files ,so to avoid you always add group:false in the spec file or move those files to manifest.mf
Thanks a lot Paolo and Jay
Very good point Jay.
Adding the library reference into the Manifest instead of the .spec file is anyhow a good strategy when many components depends on the same libraries. For example our bootstrapcomponents reference their dependencies in the MANIFEST.MF instead of repeating the same library dependency in each single .spec file
Manifest-Version: 1.0
Ant-Version: Apache Ant 1.8.4
Created-By: 1.7.0_05-b06 (Oracle Corporation)
CSS-ClientLibs: css/bootstrap/css/bootstrap.css;name=bootstrap;version=3.3.1
JS-ClientLibs: bootstrapcomponents/lib/js/bscomponents-common.js;name=bscomponents-common.js;version=1.0.0,
Bundle-Name: Bootstrap Components
Bundle-SymbolicName: bootstrapcomponents
Bundle-Version: 1.2.1
Package-Type: Web-Component
Name: button/button.spec
Web-Component: True
.....