cassette icon indicating copy to clipboard operation
cassette copied to clipboard

Create a handlebarsjs template compiler

Open mickdelaney opened this issue 13 years ago • 4 comments

i'm using handlebars templating http://www.handlebarsjs.com/
it absolutely tops jquery tmpl...

i'm willing to jump in and contribute to this feature..

i'll fork the repo and aim to get something over in the next week or 2.

anything guidance on how to proceed???

mickdelaney avatar Sep 27 '11 07:09 mickdelaney

Awesome! Are you wanting to compile the templates server side? If so the tricky bit to solve first is running the handlebars compiler within a Jurassic ScriptEngine and invoking from C#. For the jQuery tmpl compiler, I hacked the code into a single JS file that is added as a resource to the Cassette assembly: https://github.com/andrewdavey/cassette/blob/master/src/Cassette/Resources/jqueryTmplCompiler.js Something similar should work for handlebars.

For now, perhaps get a spike working in a simple console application. Then we can look at integrating it into Cassette.

andrewdavey avatar Sep 27 '11 07:09 andrewdavey

ok will do...

mickdelaney avatar Sep 27 '11 12:09 mickdelaney

Is the procedure for creating new template compiler still the same (assuming v2)?

yojimbo87 avatar May 30 '12 09:05 yojimbo87

See my pullrequest for Handlebars support

https://github.com/andrewdavey/cassette/pull/357

jpsullivan avatar Jan 31 '13 17:01 jpsullivan