function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Roy SouravRoy Sourav 

LWC - real time use cases of slots

I am new to LWC and wanted to solidify my understanding with slots. Can someone help me with some good use cases of slots. That can be achieved in a better way with slots rather than passing data to child.

Thanks in advance.
AbhishekAbhishek (Salesforce Developers) 
Hi Roy,

I suspect there you will not find much use cases.

But you can check the below blog,

https://developer.salesforce.com/docs/component-library/documentation/en/lwc/create_components_best_composition

https://developer.salesforce.com/docs/component-library/documentation/en/lwc/lwc.create_components_slots

It might help you.

Thanks.