Skip to content

support recursive with dominate.document() #163

Answered by Knio
MarisaKirisame asked this question in Q&A
Discussion options

You must be logged in to vote

i dont think it should nest

This project is not meant to be an html validator - i.e. it doesn't check that <td> is inside a <tr>, or that some tag has all the required attributes set, etc. and I don't want to special case any nodes. Also, I think nesting is legal (ok maybe only in an <embed> but I'm not going to check the whole spec)

with dominate.document() as xxx: ...
should has no other effect then writing xxx.

This is explicitly asking for it to be the context. Not doing so would break the expectations of the API. If you don't want the effect, why not just write xxx = dominate.document()?

If xxx = ... is still inside some outer context and causing problems:

but as dominate doesnt…

Replies: 4 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by Knio
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #157 on July 27, 2022 06:20.