feat #1292 Adding the ATValidateTemplates visitor in AT build and easypackage task

This commit adds the ATValidateTemplates visitor in the build and
as a configurable option in the easypackage task, so that templates
can be strictly validated during the build. This is especially useful
to find extra commas in JSON configuration objects inside templates.

This commit also adds some missing semicolons in the javascript code
generated from templates, as this is required for the ATValidateTemplates
visitor to accept templates.

close #1292