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

New slot syntax doesn't work the same way as old syntax (in some cases) #12232

Open
hivokas opened this issue Aug 20, 2021 · 3 comments · May be fixed by #12265
Open

New slot syntax doesn't work the same way as old syntax (in some cases) #12232

hivokas opened this issue Aug 20, 2021 · 3 comments · May be fixed by #12265
Labels

Comments

@hivokas
Copy link

@hivokas hivokas commented Aug 20, 2021

Version

2.6.14

Reproduction link

https://github.com/hivokas/vue-2-slots-issue

Steps to reproduce

  1. Clone the repo
  2. Run npm run serve
  3. Change the value in the text input

What is expected?

Preview updates with both old and new slot syntax (here: https://github.com/hivokas/vue-2-slots-issue/blob/cd7f3a6db790472b88421a1497ae14d4135d23ef/src/components/PublishToSocialStep.vue#L4).

What is actually happening?

Preview updates with old slot syntax, but doesn't update with new slot syntax.

Video demonstration of the problem:

20.August.2021.-.Loom.Recording.mp4

I've updated the old deprecated slot syntax to the new one.

@LinusBorg
Copy link
Member

@LinusBorg LinusBorg commented Aug 20, 2021

Hey, thanks for the detailed report. On first sight this might rather be a bug with a special combination of slot usage. We'll investigate.

@JuniorTour
Copy link

@JuniorTour JuniorTour commented Aug 29, 2021

Online Reproduction link: https://jsbin.com/sakiwam/edit?html,output

@nimatrengo
Copy link

@nimatrengo nimatrengo commented Nov 3, 2021

Hey, thanks for the detailed report. On first sight this might rather be a bug with a special combination of slot usage. We'll investigate.

As I investigated, the problem is inside src/compiler/parser/index.js inside processSlotContent method, I did not have enough time to fix it, but rawAttrsMap is doing wrong behaviour. I am new in Vue, so I just looked at it for 1 hour and it was my first time, can you guid me about this variable?

nestorrente pushed a commit to nestorrente/vue that referenced this issue Jan 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants