This repository was archived by the owner on Nov 20, 2018. It is now read-only.

Description
string.IsNullOrWhiteSpace calls char.IsWhiteSpaceLatin1 to determine if charaters are whitespace. In addition to space (0x20) it also accepts the following as whitespace
// U+0009 = <control> HORIZONTAL TAB
// U+000a = <control> LINE FEED
// U+000b = <control> VERTICAL TAB
// U+000c = <contorl> FORM FEED
// U+000d = <control> CARRIAGE RETURN
// U+0085 = <control> NEXT LINE
// U+00a0 = NO-BREAK SPACE
They will either not be in the headers (rejected by Kestrel) or would throw an exception if used in a header. However you could currently do
response.ContentType = "\r\t\n\f" + (char)(0xa0) + (char)(0x85);
To happily remove the ContentType header; which seems a little incongruous?
More importantly it doesn't inline very well 😉
/cc @Tratcher @halter73