This code trims whitespace, (fyi: it's credited to be very fast)
function wSpaceTrim(s){
var start = -1,
end = s.length;
while (s.charCodeAt(--end) < 33 ); //here
while (s.charCodeAt(++start) < 33 ); //here also
return s.slice( start, end + 1 );
}
The while loops don't have brackets, how would i correctly add brackets to this code?
while(iMean){
// like this;
}
Thank you so much!