Skip to content

Named Slot doesn't work correctly on Vue3 #526

Open
@fumiama

Description

@fumiama

Describe the bug

I'm using Vue3 but the Named Slot didn't work properly.

Steps to reproduce

Just use the code in README,

<vue-advanced-chat>
  <div slot="room-header">
    This is a new room header
  </div>
</vue-advanced-chat>

Result I got

The web is running normally but nothing changed. The room header is not replaced.

If I replace the <div slot="room-header"> to <template #room-header>, it will throw an error

[plugin:vite:vue] Codegen node is missing for element/if/for node. Apply appropriate transforms first.

Expected behavior

The room header is replaced.

Device

  • OS: MacOS Ventura 13.6.5
  • Browser: Edge 124.0.2478.51
  • Package version: 2.1.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions