static/js/org/cytoscape.js
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);
    }
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);
    }
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 ) ; }
strip spaces from beginning of string and end of string
strip spaces from beginning of string and end of string