               nav: eco.render navTemplate.toString()
               subnav: """<div class="subnav-wrapper">#{eco.render subnavTemplate.toString(), options}</div>"""
               content: """<div class="#{options.page}">#{eco.render contentTemplate.toString(), {} }</div>"""
-              scripts: js 'app'
-              templates: js 'template/index'
+              scripts: js_app
+              templates: js_templates
               user: JSON.stringify usersObj
               recurlyDomain: process.env.RECURLY_DOMAIN
               flash: req.flash()

      nav: ''
      subnav: ''
      content: ''
      scripts: js 'app'
      templates: js 'template/index'
      user: JSON.stringify usersObj
      recurlyDomain: process.env.RECURLY_DOMAIN
      flash: req.flash()

  # Trust X-Forwarded-* headers
  app.enable 'trust proxy'

  # Add Connect Assets
  # Grepability:
  # js =
  # "js" is defined in connect assets, and appears in our globals here.
  app.use assets({src: 'client'})

  # Set the public folder as static assets. In production this route
  # is served statically by nginx, so this has no effect. It's
  # used in dev, and not harmful in production.
