New: Introducing PHP and Composer Support.Read the Announcement
Socket
Book a DemoInstallSign in
Socket

@coboxcoop/replicator

Package Overview
Dependencies
Maintainers
2
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@coboxcoop/replicator

base class for replication using multifeed

Source
npmnpm
Version
1.0.1-alpha.1
Version published
Weekly downloads
9
80%
Maintainers
2
Weekly downloads
 
Created
Source

replicator

standard-readme compliant

Table of Contents

About

CoBox is an encrypted p2p file system and distributed back-up tool. README provides a map of the project.

replicator provides a base class for replication. Initialises keys with validations, sets up storage paths, initialises feeds and enables replication.

These are all common functions for any space class, so we can inherit from the replicator class to extend functionality, such as for space, or admin space, which initialize additional but different logs.

Install

npm i -g @coboxcoop/replicator

Usage

const Replicator = require('@coboxcoop/replicator')

// you can either create a replicator instance (see tests), or inherit to add further functionality, e.g.

class MyReplicatorClass {
  constructor (storage, address, identity, opts) {
    super(storage, address, identity, opts)

    // initFeeds must be called to initialize multifeed and storage correctly
    this._initFeeds({})
  }
}

API

See swagger documentation... (we won't have this for a while).

Contributing

PRs accepted.

Small note: If editing the README, please conform to the standard-readme specification.

License

AGPL-3.0-or-later

Keywords

cobox

FAQs

Package last updated on 29 Jul 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