perf(nodeName_): simplify the code and reduce the number of DOM calls