background icons
background icons 2

Video Belajar

Tonton dan pelajari berbagai topik menarik melalui video pembelajaran eksklusif dari Channel lihautan.

lihautan

4406

Svelte Tutorial for Beginners - tick()

We've learned about reactivity and reactive declarations and statements, it's time to know about the tick() function

tick() allows you to wait for all pending updates to be applied to the DOM.

In this video, I am showing 2 examples of how you could use tick() in your Svelte component.


Introduction 00:00
First example - wait for reactive declared variables to be updated 00:45
Second example - wait for updates to restore element state 05:23

---

💻 REPL https://svelte.dev/repl/a0e8adb56903414283e57d2328c3745b?version=3.35.0

🎧 Svelte Tutorial for Beginners https://www.youtube.com/playlist?list=PLoKaNN3BjQX3mxDEVG3oGJx2ByXnue_gR

📚 Related Resources
Svelte https://svelte.dev
Svelte REPL https://svelte.dev/repl
Svelte Tutorial: tick() https://svelte.dev/tutorial/tick

🥰 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 #sveltetutorial #sveltebeginner

Thanks for watching 🥰 -- with love, Li Hau