Skip to content
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

Consider having tagQuery()'s modifying methods return invisible() #219

Closed
cpsievert opened this issue Apr 20, 2021 · 2 comments · Fixed by #228
Closed

Consider having tagQuery()'s modifying methods return invisible() #219

cpsievert opened this issue Apr 20, 2021 · 2 comments · Fixed by #228

Comments

@cpsievert
Copy link
Collaborator

I find it a little surprising this prints twice

x <- div(a(), span(), a())
xq <- tagQuery(x)
xq$addClass("foo")
xq
@cpsievert
Copy link
Collaborator Author

cpsievert commented Apr 20, 2021

By hiding the result on modify, I think is a bit more clear that you're modifying xq

@schloerke
Copy link
Collaborator

I had originally approached it to be similar to plumber where the router should always be printed (never invisible).

But since it is not pipe methods, this seems fair.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants