remove test code
This commit is contained in:
parent
86f1023583
commit
25506d497c
1 changed files with 5 additions and 9 deletions
|
@ -14,11 +14,6 @@ class Clonable[T = Self](Protocol):
|
|||
def clone(self) -> T:
|
||||
return copy(self)
|
||||
|
||||
def to_element(value: ElementLike) -> "Element":
|
||||
if isinstance(value, Element):
|
||||
return value
|
||||
return Element(value)
|
||||
|
||||
# tag names
|
||||
PgSlotName = "puppygirl-slot"
|
||||
TemplateName = "template"
|
||||
|
@ -42,6 +37,11 @@ class Element(Clonable):
|
|||
|
||||
self.value = value
|
||||
|
||||
def from_element_like(value: ElementLike) -> Self:
|
||||
if isinstance(value, Element):
|
||||
return value
|
||||
return Element(value)
|
||||
|
||||
def clone(self) -> Self:
|
||||
return Element(copy(self.value))
|
||||
|
||||
|
@ -195,7 +195,3 @@ class Puppygirl:
|
|||
tag.replace_with(new_tag)
|
||||
|
||||
return tree
|
||||
|
||||
pg = Puppygirl([PuppygirlSlot])
|
||||
tree = pg.fetch("mdn.html")
|
||||
print(tree.prettify())
|
||||
|
|
Loading…
Add table
Reference in a new issue