docs: function(patterns, options) {
  	var self = this;
  	if (!(typeof patterns=='object')){throw new Error('ObsRouter constructor expects patterns object as first argument')}
  	options = options || {};
  	EventEmitter.call(self);
  	if (process.browser){
  		//bind to window by default
  		self._bindToWindow = 'bindToWindow' in options ? options.bindToWindow : true;
  		if (self._bindToWindow){
  			// add to module-scoped list of routers
  			routers.push(self);
  			// override any url input with window location
  			options.url = window.document.location.pathname + window.document.location.search;
  		}
  	}
  	// initialise state
  	self.patterns = patterns;
  	self.name = null;
  	self.params = {};
  	self.routes = {};
  	_.forEach(_.keys(self.patterns), function(route){
  		self.routes[route] = null;
  	});
  	// normalise state
  	self._update(options.url || '', false);
  	// implement initialEmit option
  	if (options.initialEmit){
  		var cancel = cancellableNextTick(function(){
  			self._emit();
  		});
  		self.once('url', cancel);
  	}
  }