@leichtgewicht/network-interfaces
TypeScript icon, indicating that this package has built-in type declarations

1.0.3 • Public • Published

network-interfaces

Build Status JavaScript Style Guide Maintainability Test Coverage

network-interfaces is similar to os.networkInterfaces() but offers a cross-platform util to listen to changes in the network setup.

npm i @leichtgewicht/network-interfaces --save

Usage

The simplest usage of it is by using creating a change-stream:

const { networkInterfaces, JSONStringMode } = require('@leichtgewicht/network-interfaces')
const { changes, warnings } = networkInterfaces.stream(JSONStringMode.line)

changes.pipe(process.stdout)
warnings.pipe(process.stderr)

By the way, you can also get this through npx 😍

$ npx @leichtgewicht/network-interfaces

API

For the time being, look into:

./index.d.ts

License

MIT

/@leichtgewicht/network-interfaces/

    Package Sidebar

    Install

    npm i @leichtgewicht/network-interfaces

    Weekly Downloads

    2

    Version

    1.0.3

    License

    MIT

    Unpacked Size

    29.8 kB

    Total Files

    21

    Last publish

    Collaborators

    • leichtgewicht