Handle blank text in createTextNode better.