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

bugfix: adding children to emotion jsx function #166

Merged
merged 1 commit into from
Jan 10, 2021
Merged

bugfix: adding children to emotion jsx function #166

merged 1 commit into from
Jan 10, 2021

Conversation

marceloadsj
Copy link
Contributor

Summary

A bug on the xstyled/emotion jsx API makes the children of tags with "css" props to not be rendered:

<div css={{...}}>
  <p>A paragraph</p> // currently, this will not be rendered
</div>

So, this PR fixes this issue and creates some tests to ensure its stability.

Test plan

3 tests were created:

  • Empty
    does not render any content
  • with a single children renders the content
  • with multiple children renders all elements

Before:
image

After:
image

@marceloadsj marceloadsj changed the title fix: adding children to emotion jsx function bugfix: adding children to emotion jsx function Jan 10, 2021
@gregberge gregberge merged commit 6bc0d4e into styled-components:master Jan 10, 2021
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

2 participants