code: function(id, soft) {
          var comp = components[id];
          this.trigger("RemoveComponent", id);
          if (comp && "events" in comp) {
              var auto = comp.events;
              for (var eventName in auto) {
                  var fn =
                      typeof auto[eventName] === "function"
                          ? auto[eventName]
                          : comp[auto[eventName]];
                  this.unbind(eventName, fn);
              }
          }
          if (comp && "remove" in comp) {
              comp.remove.call(this, false);
          }
          if (soft === false && comp) {
              for (var prop in comp) {
                  delete this[prop];
              }
          }
          delete this.__c[id];
          // update map from component to (entityId -> entity)
          if (compEntities[id]) {
              delete compEntities[id][this[0]];
          }
  
          return this;
      }
docs: @
  #.removeComponent
  @comp Crafty Core
  @kind Method
  
  @sign public this .removeComponent(String Component[, soft])
  @param component - Component to remove
  @param soft - Whether to soft remove it (defaults to `true`)
  
  Removes a component from an entity. A soft remove (the default) will only
  refrain `.has()` from returning true. Hard will remove all
  associated properties and methods.
  
  @example
  ~~~
  var e = Crafty.e("2D,DOM,Test");
  e.removeComponent("Test");        //Soft remove Test component
  e.removeComponent("Test", false); //Hard remove Test component
  ~~~