ilp-plugin-multiplex

1.1.3 • Public • Published

ILP Plugin Multiplex

Create multiple children of an ILP plugin in the same process

Example

const PluginMultiplex = require('ilp-plugin-multiplex')

// Create a parent
// (typically this is done as part of a connector config)
const plugin = new PluginMultiplex({})

// Create a child
const childPlugin1 = plugin.getChild()

// Create a child with custom id
// (this id is an address segment)
const childPlugin2 = plugin.getChild({ id: 'abcdef' })

Why?

The same use case as mini-accounts, but sometimes you want to do it within a single process. Mini accounts binds to a port which can be undesirable in some situations, esp. in a browser where that's not possible.

Readme

Keywords

none

Package Sidebar

Install

npm i ilp-plugin-multiplex

Weekly Downloads

0

Version

1.1.3

License

ISC

Unpacked Size

5.04 kB

Total Files

4

Last publish

Collaborators

  • sharafian