Skip to content

Functional components render slots with strings as empty divs #693

Closed
@danielsdeboer

Description

@danielsdeboer

Version

1.0.0-beta.16

Reproduction link

https://codesandbox.io/s/j376k9jvv

Steps to reproduce

  • Create a basic functional component that renders content from the default slot
  • Attempt to mount the component with a string in the default slot

What is expected?

Should render the string, eg <p>Some string</p>

What is actually happening?

Test utils renders an empty <div>, eg <p><div></div></p>


The component works as expected outside of the test environment. See the repro, where slotted content renders as expected.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions