How to set timer idle in Vue

Do you need to check for inactivity of the user in your Vue apps? If the user is inactive in a period of time, then you wanna to automatically logout the user or show a timer first.