Prevented generation of illegal elements

Previously, text like <-> would try to generate an element with an
illegal name, causing a JS error