I'd like to find out about libraries with the following properties:
- Javascript implementation for client-side,
- Java implementation for server-side,
- light-weight syntax: no generic 'code', only simple expressions,
- but simple for-loops, 'include', and 'if'.
(In short, the syntax would be similar to Django templates, if that tells you anything.)
Does anybody know an open-source library that fulfills these requirements?
Have you considered using Mustache? It offers very simple templates and can be used in both java and javascript.
If you look at the docs you can see simple examples of loops:
and conditions:
Includes can be handled by using partials, which let you pull in another template.