VueUse for Everyone: Unlock Vue.js Composition Power
Plans from $25/month

This lesson is for members. Join us?

Subscribe now and get immediate access to this course, 30 more and all future Vue.js courses!

Timeouts and VueUse

In this lesson, we take a look at useTimeout and useTimeoutFn VueUse composables for performing actions after a specified period of time. These composables can be useful for automatically hiding alerts after a delay.

While not mentioned during the lesson, it’s also worth sharing that VueUse exposes a promiseTimeout utility function that returns a promise that resolves after the specified timeout.

Links