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

Allow Svelte components to be slot roots #1713

Closed
andyjessop opened this issue Sep 5, 2018 · 2 comments
Closed

Allow Svelte components to be slot roots #1713

andyjessop opened this issue Sep 5, 2018 · 2 comments

Comments

@andyjessop
Copy link

andyjessop commented Sep 5, 2018

https://svelte.technology/repl?version=2.13.2&gist=1a69018031dc8c34d013de01a70579a1

Instead of this:

<Layout>
  <Component slot="my-slot" />
</Layout>

I have to do this:

<Layout>
  <div slot="my-slot">
    <Component />
  </div>
</Layout>

This adds an unnecessary DOM layer and possibly means adjusting CSS.

@chris-morgan
Copy link
Contributor

(Exact duplicate of #1037.)

@Conduitry
Copy link
Member

Closing as dupe of #1037

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

No branches or pull requests

3 participants