docs: function middleware(options) {
  
  	var options       = _.extend({}, require('./defaultOptions.js'), options || {})
  	  , bootstrapPath = join(options.client, options.bootstrap)
  	  , regClient     = new RegExp('^' + options.client + '\/[^\.\/]*\\'+ options.extension + '$')
  	;
  
  	return function(req, res, next) {
  		if ('GET' != req.method && 'HEAD' != req.method) return next();
  		var path = url.parse(req.url).pathname
  		  , dir  = dirname(path)
  		;
  
  		if(dir != options.client) return next();
  
  		res.setHeader('X-nway-Middleware', require('../package.json').version);
  
  		if(path == bootstrapPath) {
  			// No cache
  			res.setHeader('Cache-Control', 'no-cache, must-revalidate, max-age=-1');
  			res.setHeader('X-nway-Middleware-nocache', '1');
  		} else if(regClient.test(path)) {
  			// One year cache :
  			res.setHeader('Cache-Control', 'public, max-age=' + cacheMaxAge);
  			res.setHeader('X-nway-Middleware-nocache', '0');
  		}
  
  		next();
  	}
  
  }