aboutsummaryrefslogtreecommitdiff
path: root/mammoth/html/nodes.py
diff options
context:
space:
mode:
authorMichael Williamson <mike@zwobble.org>2016-03-14 18:56:42 +0000
committerMichael Williamson <mike@zwobble.org>2016-03-14 20:09:13 +0000
commitb34f7280c0754f9fc88725358e22ac46d9a2a598 (patch)
tree350a5563a0cd06bb8c97e932f7f275edc4106705 /mammoth/html/nodes.py
parent8f3486e5fc69f2402476b830d21b271a93ed0046 (diff)
Add collapsing of HTML nodes
Diffstat (limited to 'mammoth/html/nodes.py')
-rw-r--r--mammoth/html/nodes.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/mammoth/html/nodes.py b/mammoth/html/nodes.py
index aae4888..a5a5bde 100644
--- a/mammoth/html/nodes.py
+++ b/mammoth/html/nodes.py
@@ -16,6 +16,10 @@ class Element(Node):
attributes = cobble.field()
children = cobble.field()
collapsible = cobble.field()
+
+ @property
+ def tag_name(self):
+ return self.tag_names[0]
@cobble.data