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

node-usb-detection

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-usb-detection

A small library that surfaces node-usb's hotplug detection

latest
Source
npmnpm
Version
1.0.2
Version published
Maintainers
1
Created
Source

node-usb-detection

###A simple interface for attaching callbacks to usb plug and unplug events.

Installation

npm install node-usb-detection --save

Usage

var monitor = require('node-usb-detection');


console.log("Usb Devices:\n", monitor.list());

monitor.add(function(device) {
    console.log("added device:\n", device);
});

monitor.remove(function(device) {
    console.log("removed device:\n", device);
});

monitor.change(function(device) {
    console.log("device changed:\n", device);
});

License

MIT

Note that the compiled Node extension includes Libusb, and is thus subject to the LGPL.

Keywords

node

FAQs

Package last updated on 20 Jun 2015

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