Recommended JavaScript HTML template library for JQuery? [closed]

Well, to be frank, client-side templating is very hot nowadays, but quite a jungle.

the most popular are, I believe:

  • pure: It use only js, not his own
    “syntax”
  • mustache: quite stable and nice I
    heard.
  • jqote2: extremely fast
    according to jsperfs
  • jquery templates (deprecated):

there are plenty others, but you have to test them to see what suits you, and your project style, best.

Personally, I have a hard time with adding a new syntax and set of logic (mixing logic and template, hello??), and went pure js. Every single one of my templates is stored in it’s own html file (./usersTable.row.html). I use templates only when ajaxing content, and I have few “logic” js files, one for tables, one for div, one for lists. and not even one for select’s options (where i use another method).

Each time I tried to do something more complex, I found out the code was less clear and taking me more time to stabilize than doing it the “old” way. Logic in the template is an utter non-sense in my opinion, and adding it’s own syntax adds only very-hard-to-trace bugs.

Leave a Comment