If you grep `nodeType` through React codebase, there are a couple of other places where for example TEXT_NODE is hardcoded as 3, don't know if those should be included too (some of those may be vendored in) or perhaps in another pull request.