Returns the node tag name. Returns null if node is not an Element.
node
String? getElementTagName(Node node) => node is Element ? node.tagName.toLowerCase() : null;