register-protocol-handler-windows

1.0.1 • Public • Published

register-protocol-handler-windows

register protocol handlers on Windows

usage

var registerProtocolHandler = require('register-protocol-handler-windows')
 
var shellCommand = '"c:\\foo.exe" "%1"' // %1 gets replaced with the URL
var register = registerProtocolHandler('foo', shellCommand, 'The Foo Protocol')
 
register.then(function () {
  console.log('registered ok!')
})
.catch(function (e) {
  console.log('registration failed:', e)
})

api

Matches (as closesly as possible) the DOM Navigator.registerProtocolHandler API

registerProtocolHandler(protocol, path, name) => Promise

installation

$ npm install register-protocol-handler-windows

running the tests

From package root:

$ npm install
$ npm test

related documentation

MSDN: Registering an Application to a URI Scheme

contributors

license

ISC. (c) MMXV jden jason@denizac.org. See LICENSE.md

Package Sidebar

Install

npm i register-protocol-handler-windows

Weekly Downloads

0

Version

1.0.1

License

ISC

Last publish

Collaborators