tauren / tmpl-precompile

Precompile jade templates into executable functions
MIT License
25 stars 7 forks source link

Add callback to precompile function, make sure console.log only happens when verbose #11

Closed jescalan closed 11 years ago

jescalan commented 11 years ago

Two things added here. The first is a callback for the exported precompile function, which is really useful if you are integrating this tool programmatically. The second is that there was no way to prevent console.logs from being fired for some of them, this is not something you want when integrating with another library. I set all the console.log calls only to fire when the verbose option was specified.

Nothing crazy, just a little patching I needed to be able to integrate this with roots for an upcoming client-side js framework update. Really awesome work on this library, this saved me so much time :smile:

samccone commented 11 years ago

:thumbsup:

tauren commented 11 years ago

Thanks! Request has been merged.

jescalan commented 11 years ago

Whoo! Could you post an update here when there's a new push to npm so I can switch to using master rather than my fork? Thanks so much :shipit: