WMA link
Whitespace
StringMatchQ["\r \n", Whitespace]
StringSplit["a \n b \r\n c d", Whitespace]
StringReplace[" this has leading and trailing whitespace \n ", (StartOfString ~~ Whitespace) | (Whitespace ~~ EndOfString) -> ""] <> " removed" // FullForm