Slots break when passing to child component

This issue has been created since 2022-07-28.

Version

2.7.8

Reproduction link

github.com/johannes-z/vue27

Steps to reproduce

  1. git clone https://github.com/johannes-z/vue27.git
  2. git checkout -b bug/slots
  3. pnpm install
  4. pnpm run dev

What is expected?

ChildComponent should print customSlot AND rootSlot.

expected rendered HTML:

<div>
   <div>test</div>
   <div>default: </div>
   <div>rootSlot: scopedSlot from Root</div>
   <div>customSlot: <b>scopedSlot from MainComponent</b></div>
</div>

What is actually happening?

rootSlot is missing already missing from $scopedSlots inside MainComponent.

actually rendered HTML:

<div>
   <div>test</div>
   <div>default: scopedSlot from Root</div>
   <div>rootSlot: </div>
   <div>customSlot: <b>scopedSlot from MainComponent</b></div>
</div>

yyx990803 wrote this answer on 2022-08-19

Your app template slot syntax is wrong:

- <template name="rootSlot" slot-scope="props">
+ <template slot="rootSlot" slot-scope="props">
More Details About Repo
Owner Name vuejs
Repo Name vue
Full Name vuejs/vue
Language TypeScript
Created Date 2013-07-29
Updated Date 2022-09-27
Star Count 199644
Watcher Count 6098
Fork Count 32848
Issue Count 587

YOU MAY BE INTERESTED

Issue Title Created Date Comment Count Updated Date
Please make the 2.0.0 available in maven central 7 2022-06-22 2022-09-18
the printer stops doing its job 10 2021-12-03 2022-09-24
Replace spacenation/swiftui-charts with danielgindi/Charts 0 2021-11-10 2022-06-29
Sequencer - Theming, New title bar might need some work (too black) 10 2022-04-29 2022-07-14
Dope Sheet Context menu - Delete Breakdowns needs icon 2 2022-04-26 2022-07-27
ak.randint() fails for ranges greater than 2**63 1 2022-03-03 2022-07-14
It's not a bug but... it doesn't work on uploadheaven... 0 2022-08-18 2022-09-19
[Feature Request] Separate dose threshhold for matRad_gammaIndex 0 2021-07-14 2022-09-20
Different number of threads for reads and writes, for Chia Farming/Plotting 8 2021-08-26 2022-09-02
Bug Report: Can't compile on Linux 8 2021-07-03 2022-08-31
Screen goes black whenever I go underground 0 2021-09-11 2022-09-04
Linux Newbie - Correct method for updating breach list 0 2021-11-04 2022-08-08
Unable to launch quickgui 3 2022-02-25 2022-09-17
Is there a specific setting to run a quality analysis? 1 2021-01-12 2022-09-25
unattended usage of aztfy 1 2022-05-19 2022-09-14
🐛 [Bug] TRTorch runtime isn't threadsafe,which maybe segment-fault or hang in online-serving multi-thread environment 2 2021-09-03 2022-08-12
Docker support for Mac OS 1 2022-04-26 2022-09-17
[Intel]: https://twitter.com/ESETresearch/status/1382054011264700416 0 2022-04-20 2022-09-23
TAStudio scroll behavior bug when Follow Cursor is enabled 4 2021-10-12 2022-08-06
aggregate netflow data by the 5-tuple protocol, srcip, dstip, srcport and dstport. 3 2022-07-16 2022-09-03
[Icon request] Workspace, Session and Startup, Blueman-adapters, About Xfce, MIME Type Editor 0 2021-05-17 2022-08-16
npm ERR! ERESOLVE unable to resolve dependency tree 1 2022-08-30 2022-09-20
Paru not recognising AUR package updates after deleting local repository 3 2022-02-25 2022-09-24
feat(useSliceUpload): the file slice upload function 1 2022-04-26 2022-09-24
update icons for the app 0 2021-11-01 2022-08-09
[CoSim] Compilation problem 2 2021-11-04 2022-09-10
Problem with docker image initialization 1 2021-04-09 2022-07-27
Services crash without log. 6 2020-12-17 2022-09-19
Document which ports need to be open when running behind a NAT 1 2021-01-13 2022-09-19
read_csv_glob fails reading from azure storage account 9 2022-04-25 2022-09-16
stddev* and var* family of function cannot be applied to Decimal* types 0 2022-06-03 2022-09-11
[GOVC] Add a new command to support move host from datacenter to cluster 4 2021-07-21 2022-08-30
More explanation about settings 0 2016-09-21 2022-08-24
Flatpak Packaging 2 2021-01-13 2022-01-12
PosixPipeInput.close() hangs the application 1 2021-11-03 2022-09-23
Arduino Avr device registers undefined 1 2021-12-30 2022-09-23
Grafana E2E package doesn't support mono-repos 0 2022-02-16 2022-09-26
与好友聊天界面“双击加载历史消息”不可用,但群聊可正常自动加载。 7 2021-10-03 2022-08-26
non-preview version rule preventing the use of WorkspaceResourceId in Application Insights. 1 2021-06-28 2022-09-09
Improve description of some env variables 0 2022-09-19 2022-09-25
[ECS] [Feature Request]: ECS Anywhere support for EFS - amazon-ecs-volume plugin 0 2021-06-14 2022-02-04
Lack of disk space on default AWS Batch ComputeEnvironment 1 2021-02-20 2022-09-24
`cargo test` is broken despite specified `--rust-target 1.47` 3 2022-09-22 2022-09-18
[Bug] [Permission] Workflow definition list error 6 2022-02-28 2022-09-24
Interactive Window session lost without warning when changing folders 9 2022-06-01 2022-09-26
Enhancement - Any interest in a helper function to show exercise by number? 0 2019-03-07 2022-09-23
rx library implementation? 3 2018-04-27 2022-09-24
Left hand wrist cable broken 7 2021-11-20 2022-09-21
Update "Extensions and the add-on ID" page to mention the MV3+ requirement 1 2022-05-11 2022-09-17
spring boot 2.7.3 - r2dbc-pool 2 2022-08-23 2022-09-24