strip

strip whitespace from given string


Parameters

strip string :string :literal :pathliteral

Attributes

start strip leading whitespace
end strip trailing whitespace

Returns

  • :string
  • or  :nothing

Examples

copy
str: " Hello World " print ["strip all:" ">" strip str "<"] print ["strip leading:" ">" strip.start str "<"] print ["strip trailing:" ">" strip.end str "<"] ; strip all: > Hello World < ; strip leading: > Hello World < ; strip trailing: > Hello World <

Related