mirror of
https://github.com/anomalyco/opentui.git
synced 2026-04-24 20:45:56 +03:00
[GH-ISSUE #197] Conditional components not rendered and causing layout issues #812
Labels
No labels
bug
core
documentation
feature
good first issue
help wanted
pull-request
question
react
solid
tmux
windows
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/opentui#812
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @magnuswahlstrand on GitHub (Oct 2, 2025).
Original GitHub issue: https://github.com/anomalyco/opentui/issues/197
Hi! Feel free to close this ticket if you are not open for this type of bug reports 🙂
How to reproduce:
{foo && <box><text content={foo} /></box>}foois updated (alternated between falsy and truthyIssues:
foobecomes truthyfoobecomes truthy, horizontal height is added, but when it is falsy, it is not removedFull snippet:
@remorses commented on GitHub (Oct 2, 2025):
Try passing the text as children instead of content prop
@magnuswahlstrand commented on GitHub (Oct 2, 2025):
Same problem with
@eli0shin commented on GitHub (Oct 6, 2025):
I'm testing this and it seems to be another insertBefore issue but it doesn't really make sense because box does seem to track children and handle insertBefore properly.
This example works if it is modified to either remove the box after the conditional box or to make the conditional box constant and make just its contents conditional.