dbashford / mimosa-client-jade-static

A mimosa module to use jade to create HTML client templates
2 stars 4 forks source link

feature request: define an object in mimosa-config to pass into template render call? #2

Closed breathe closed 11 years ago

breathe commented 11 years ago

It would be great to be able to define an object within the client-jade-static mimosa config which is passed into each template's render context:

client-jade-static:
   context:
      info: 'useful project info!'
      debug: false
      reload: true

which would allow such dynamic constructs within the template:

=info
if reload
   script(src='socket.io/socket.io.js')
   script(src='javascripts/reload-client.js')
if debug
   some_debug ...