-
Notifications
You must be signed in to change notification settings - Fork 841
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add remove #653
Add remove #653
Conversation
@@ -856,7 +856,7 @@ def _register_child(self, parent: DOMNode, child: DOMNode) -> bool: | |||
return True | |||
return False | |||
|
|||
def register( | |||
def _register( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Devs should never need to call this directly.
There are probably a number of other methods that should be private. Will be an ongoing process to identify them
@@ -36,14 +37,16 @@ def __init__( | |||
self, | |||
node: DOMNode | None = None, | |||
selector: str | None = None, | |||
nodes: list[DOMNode] | None = None, | |||
nodes: list[Widget] | None = None, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Queries now return Widgets rather than DOMNodes. This means that it excludes App, which is find since it is a special object that doesn't have any visuals. Although you can still reference App in a selector.
Implements a
remove()
method to remove a widget from the DOM.