File tree Expand file tree Collapse file tree 3 files changed +16
-1
lines changed
Expand file tree Collapse file tree 3 files changed +16
-1
lines changed Original file line number Diff line number Diff line change 1414- Improve unicode handling for malformed text. Resolves #138 .
1515- Fix segfaults when doing double ` .decompose ` . Resolves #179 .
1616- Fix sefgaults when doing double ` .unwrap ` . Resolves #169 .
17+ - Fix typo for tag names. Clarify available tag names.
1718
1819## Version 0.3.34
1920
Original file line number Diff line number Diff line change @@ -267,6 +267,12 @@ class LexborNode:
267267 def tag (self ) -> str | None :
268268 """Return the name of the current tag (e.g. div, p, img).
269269
270+ For for non-tag nodes, returns the following names:
271+
272+ * `-text` - text node
273+ * `-document` - document node
274+ * `-comment` - comment node
275+
270276 Returns
271277 -------
272278 text : str
Original file line number Diff line number Diff line change @@ -6,7 +6,7 @@ import logging
66logger = logging.getLogger(" selectolax" )
77
88_TAG_TO_NAME = {
9- 0x0005 : " - doctype" ,
9+ 0x0005 : " -doctype" ,
1010 0x0002 : " -text" ,
1111 0x0004 : " -comment" ,
1212}
@@ -261,6 +261,14 @@ cdef class LexborNode:
261261 def tag (self ):
262262 """ Return the name of the current tag (e.g. div, p, img).
263263
264+ For for non-tag nodes, returns the following names:
265+
266+ * `-text` - text node
267+ * `-document` - document node
268+ * `-comment` - comment node
269+
270+ This
271+
264272 Returns
265273 -------
266274 text : str
You can’t perform that action at this time.
0 commit comments