docs: function( str ){
        var first, last;
  
        // find first non-space char
        for( first = 0; first < str.length && str[first] === ' '; first++ ){}
  
        // find last non-space char
        for( last = str.length - 1; last > first && str[last] === ' '; last-- ){}
  
        return str.substring(first, last + 1);
      }