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
Qute: execute tag templates in isolation by default #35600
Conversation
🙈 The PR is closed and the preview is expired. |
By default, a tag template cannot reference the data from the parent context. | ||
Qute executes the tag as an _isolated_ template, i.e. without access to the context of the template that calls the tag. | ||
However, sometimes it might be useful to change the default behavior and disable the isolation. | ||
In this case, just add `_isolated=false` to the call site, for example `{#itemDetail item showImage=true _isolated=false /}`. |
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.
I would use the opposite word: _contextual=true
(or any other better word)
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.
Hm, contextual
is IMO too overloaded. isolated
was already there but I didn't find a good antonym... In any case, we could add a "positive" alias. Maybe something like _connected
or even just _unisolated
(note that the =true
part is optional)?
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.
Looks good, just one small suggestion
647b5ca
to
6d744f5
Compare
6d744f5
to
5ae4d25
Compare
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.
Thanks!
This comment has been minimized.
This comment has been minimized.
✔️ The latest workflow run for the pull request has completed successfully. It should be safe to merge provided you have a look at the other checks in the summary. |
This PR is a follows-up of #22003.