torso-bundle.js
function($el, options) {
      options = options || {};
      var view = this;
      if (!this.isAttachedToParent()) {
        this.__pendingAttachInfo = {
          $el: $el,
          options: options
        };
        return this.render().done(function() {
          if (!view.__attachedCallbackInvoked && view.isAttached()) {
            view.__invokeAttached();
          }
          view.__isAttachedToParent = true;
        });
      }
      return $.Deferred().resolve().promise();
    }
function($el, options) {
      options = options || {};
      var view = this;
      if (!this.isAttachedToParent()) {
        this.__pendingAttachInfo = {
          $el: $el,
          options: options
        };
        return this.render().done(function() {
          if (!view.__attachedCallbackInvoked && view.isAttached()) {
            view.__invokeAttached();
          }
          view.__isAttachedToParent = true;
        });
      }
      return $.Deferred().resolve().promise();
    }
function ( $el , options ) { options = options || { } ; var view = this ; if ( ! this . isAttachedToParent ( ) ) { this . __pendingAttachInfo = { $el : $el , options : options } ; return this . render ( ) . done ( function ( ) { if ( ! view . __attachedCallbackInvoked && view . isAttached ( ) ) { view . __invokeAttached ( ) ; } view . __isAttachedToParent = true ; } ) ; } return $ . Deferred ( ) . resolve ( ) . promise ( ) ; }
If detached, will replace the element passed in with this view's element and activate the view.
@param [$el] {jQuery element} the element to attach to. This element will be replaced with this view.
If options.replaceMethod is provided, then this parameter is ignored.
@param [options] {Object} optional options
@param   [options.replaceMethod] {Fucntion} if given, this view will invoke replaceMethod function
in order to attach the view's DOM to the parent instead of calling $el.replaceWith
@param   [options.discardInjectionSite=false] {Booleon} if set to true, the injection site is not saved.
@return {Promise} promise that when resolved, the attach process is complete. Normally this method is synchronous. Transition effects can
make it asynchronous.
@method attachTo
If detached will replace the element passed in with this view s element and activate the view .