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

node-native-messaging-host

Package Overview
Dependencies
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-native-messaging-host

Simple Node Native Messaging Host =================================

latest
Source
npmnpm
Version
1.0.5
Version published
Maintainers
1
Created
Source

Simple Node Native Messaging Host

A native messaging host for Chrome and Firefox with a simple API and no dependencies.

Install

npm i node-native-messaging-host

Usage

import initNativeMessagingHost from 'node-native-messaging-host';

// Initialize
const nm = initNativeMessagingHost();

// Add a callback that will be fired each time a new message is
// received from the extension.
nm.addOnMessageListener(message => {
    console.log(`Received ${message} from extension`);
});


// Send a message to the extension
nm.send({ answer: 42 });

Used by

Todo

  • tests

Keywords

native-messaging-host

FAQs

Package last updated on 18 Feb 2020

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