title: NodeJs: Load different CSS depending on routes parameters
body: <p>I've looked around a bit, but I'm not even sure that what I want is possible. </p>
  
  <p>app.js</p>
  
  <pre><code>...
  var routes = require('./routes/index');
  ...
  app.use('/', routes);
  ...
  </code></pre>
  
  <p>index.js</p>
  
  <pre><code>/* GET home page. */
  router.get('/', function(req, res, next) {
      res.render('index', { 
          title: 'Test',
          headersheet: 'header',
          mainsheet: 'devTest',
          navbar: 'nav_bar',
          mainscript: 'devTest',
      });
  });
  </code></pre>
  
  <p>Then, my layout.jade</p>
  
  <pre><code>doctype html
  html
      head
          title= title
          link(rel='stylesheet', href='/stylesheets/global.css')
          link(rel='stylesheet', href='/stylesheets/#{headersheet}.css')
          link(rel='stylesheet', href='/stylesheets/#{mainsheet}.css')
          link(rel='stylesheet', href='/stylesheets/#{navbar}.css')
      body
          block content
          script(src='http://ajax.googleapis.com/ajax/libs/jquery/2.0.3/jquery.min.js')
          script(src='javascripts/#{mainscript}.js')
  </code></pre>
  
  <p>index.jade</p>
  
  <pre><code>extends layout
  
  block content   
      include nav_bar.jade
  
      #page_header_fr
  </code></pre>
  
  <p>Basically what I want is that the <code>#{mainsheet}.css</code> becomes <code>devTest.css</code></p>
  
  <p>But what I see in my consoles when the pages load is a message telling me that the resource <code>undefined.css</code> could not be find. Now, what I understand from that is that the parameters (headersheet, mainsheet, navbar, ...) are not properly being transmitted. However, the title of the page displays just fine. </p>
  
  <p>Is it even possible to do this?</p>