Live data from Hacker News

Javascript Templating Engine Chooser

garann.github.io

31–33 of 33 posts

Re: Javascript Templating Engine Chooser

#32
post #3

It's missing DustJS, which is IMO a strong contender that does well in benchmarks http://linkedin.github.io/dustjs/ * Works in the browser and on the server * Pretty fast * logic-less but with a helpers API for when you need more power * pre-compiles templates * has template partials

Dust is not logic-less, even disregarding the helpers.

Re: Javascript Templating Engine Chooser

#33
post #9

Is there a way to deselect an option without reloading the page? For example: Under "DOM Structure", once you select "DOM" or "String", you can never go back to seeing all the template options.

It seems a little buggy. There seem to be several state combinations that cause it to lock up.

The "app" is just a bit of jquery that hides/shows divs based on their classes. It skips a refresh if the filter is empty ( to avoid creating an invalid jquery selector?), so if you set "View Partials" to "Yes" and then "No", nothing changes. Anyways, I just forked it and fixed it.

http://xinsight.github.io/template-chooser/

This is a simple little app, but it's a good example of how using the DOM as a model and a view (as most jquery apps do) doesn't create the most elegant code.

Post reply on HN