ee.String.trim

Returns a string whose value is the original string, with any leading and trailing whitespace removed.

UsageReturns
String.trim()String
ArgumentTypeDetails
this: stringString

The string to trim.

Examples

Code Editor (JavaScript)

var s = ee.String('\t\n\r abc\t\n\r ');
print(s.trim());  // "abc"

var s = ee.String(' a\t\n\r b ');
print(s.trim());  // "a\t\n\r b"