Skip to content

Listen to the door (node) then do the action when it's opened or closed.

License

Notifications You must be signed in to change notification settings

wongnai/door-listener

Repository files navigation

door-listener

semantic-release JavaScript Style Guide ts code style: prettier License: MIT

Listen to the door (Node process) and do something!

Installation

yarn add door-listener

Usage

import { onClose, onOpen } from 'door-listener'

// Top of your entry code
onOpen(() => {
    // do something
})

onClose(() => {
    // do something
})

About

Listen to the door (node) then do the action when it's opened or closed.

Resources

License

Stars

Watchers

Forks

Packages

No packages published