Sightly pages are written in HTL which is HTML template language.
HTL is made simple so that it is easy to use by web developers as well as backend developers.
HTL makes use of HTML5
HTL pages are compiled as java serlvets and it is evaluated at server side.
HTL is capable of applying proper context to the data which means it is more secure than JSP.
HTL can include a jsp file
HTL block statements can not be defined inside script, style or html comments.
Context aware escaping that saves from cross site scripting attacks.
Javascript USE api is evaluated by serverside javascript engine.
HTL removes empty elements automatically
Block Statements:
data-sly-use
data-sly-unwrap
data-sly-call
data-sly-template
data-sly-text
data-slty-attribute
data-sly-test
data-sly-list
data-sly-resource
data-sly-include
Expressions:
${name}
${currentPage.title} or ${currentPage["title"]} or ${currentPage['title']}
${true} or {false}
${45}
${"test"}
${[1,2,3,4]}
${array[1]}
${!true}
${ a > b}
${a && b}
${a || b }
${ a < b ? a : b }
${a == b}
${a != b}
${a @ test='test'}
$ {['a','b'] @ join=", "}
No comments:
Post a Comment
If you have any doubts or questions, please let us know.