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

Use React fragments to avoid wrapping elements #2018

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

hanydd
Copy link
Contributor

@hanydd hanydd commented May 11, 2024

  • I agree to license my contribution under GPL-3.0 and agree to allow distribution on app stores as outlined in LICENSE-APPSTORE

Currently, the component renders another <span> and put all the conditional elements inside, which makes the same-level elements reside in separate wrapping spans. Using React fragments (<></>) as a wrapping placeholder can solve this. And it allowed for better layout controls, such as using flow or grid.

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 this pull request may close these issues.

None yet

1 participant