New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

@twoavy/idle-timer

Package Overview
Dependencies
Maintainers
3
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@twoavy/idle-timer

A timer resetting itself on click & touch

latest
Source
npmnpm
Version
2.0.6
Version published
Maintainers
3
Created
Source

idle-timer

A Vue plugin to track idle time

Installation

npm i @twoavy/idle-timer
OR
yarn add @twoavy/idle-timer
import idleTimer from 'idle-timer';

Usage

####Initialize (main.js)

app.use(idleTimer, {
    idleTime: 30, // secs
    trigger: ['mousedown', 'touchstart']
})

####In component (within setup)

// idle event
const idleTimer = inject('idle-timer')
idleTimer.emitter.on('idle', () => {
    console.log('idle')
})

// restart
idleTimer.restart()

FAQs

Package last updated on 11 Oct 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts