examples/map/js/backbone.marionette.js
function(name, definition){
      var region;

      var isObject = _.isObject(definition);
      var isString = _.isString(definition);
      var hasSelector = !!definition.selector;

      if (isString || (isObject && hasSelector)){
        region = Marionette.Region.buildRegion(definition, Marionette.Region);
      } else if (_.isFunction(definition)){
        region = Marionette.Region.buildRegion(definition, Marionette.Region);
      } else {
        region = definition;
      }

      this._store(name, region);
      this.triggerMethod("region:add", name, region);
      return region;
    }
function(name, definition){
      var region;

      var isObject = _.isObject(definition);
      var isString = _.isString(definition);
      var hasSelector = !!definition.selector;

      if (isString || (isObject && hasSelector)){
        region = Marionette.Region.buildRegion(definition, Marionette.Region);
      } else if (_.isFunction(definition)){
        region = Marionette.Region.buildRegion(definition, Marionette.Region);
      } else {
        region = definition;
      }

      this._store(name, region);
      this.triggerMethod("region:add", name, region);
      return region;
    }
function ( name , definition ) { var region ; var isObject = _ . isObject ( definition ) ; var isString = _ . isString ( definition ) ; var hasSelector = ! ! definition . selector ; if ( isString || ( isObject && hasSelector ) ) { region = Marionette . Region . buildRegion ( definition , Marionette . Region ) ; } else if ( _ . isFunction ( definition ) ) { region = Marionette . Region . buildRegion ( definition , Marionette . Region ) ; } else { region = definition ; } this . _store ( name , region ) ; this . triggerMethod ( "region:add" , name , region ) ; return region ; }
Add an individual region to the region manager, and return the region instance
Add an individual region to the region manager and return the region instance