Video details

Svelte Question - How to pass Svelte component through props?

Svelte
06.07.2021
English

How to use pass Svelte component through props?
You can pass string / element / component through React props,
but you can't do it for Svelte!
Elements within attribute is not a valid HTML syntax nor Svelte syntax!
However, in Svelte, you can have named slots, and named slots allow you to pass in different types of content.
---
🎧 Svelte Tutorial for Beginners https://www.youtube.com/playlist?list=PLoKaNN3BjQX3mxDEVG3oGJx2ByXnue_gR 🎧 Svelte Question Time https://www.youtube.com/playlist?list=PLoKaNN3BjQX1I9FmIoCaws4vUaoqezpc1 🔗 Stack Overflow Question https://stackoverflow.com/questions/67852559/pass-svelte-component-as-props/67855249
📚
Related Resources Svelte https://svelte.dev Svelte REPL https://svelte.dev/repl
🥰 Support me https://www.buymeacoffee.com/lihautan
🔗
Want to learn more from me? Check out these links:

Twitter: https://twitter.com/lihautan Blog: https://lihautan.com/ Newsletter: https://lihautan.com/newsletter
#svelte #sveltequestiontime
Thanks for watching 🥰 -- with love, Li Hau