0 votes
in VueJS by
What are the difference between slots and scoped slots in Vue JS

1 Answer

0 votes
by

A slot is a placeholder in a child component that is filled with content passed from the parent. Content of a regular slot is compiled in the parent’s scope and then passed to the child component.

Thus you can’t use child component properties in a slot’s content. But scoped slots allow you to pass child component data to the parent scope and then use that data in slot content.

Related questions

0 votes
asked Oct 9, 2019 in VueJS by Indian
0 votes
asked Oct 7, 2019 in VueJS by Tate
...