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

level-user

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

level-user

client side library for moving data over a level-socket

latest
Source
npmnpm
Version
1.2.0
Version published
Maintainers
1
Created
Source

level-user

experimental

client side library for authenticating with and moving data over a level-socket (authenticated binary websocket)

npm install level-user

usage

var user = require('level-user')({ dbName: 'blocks', baseURL: "http://localhost:8080" })

baseURL is where level-socket is running, dbName is the name of the level-js db data should be stored in

user has .db and .persona

user.getSession(cb)

checks the users session state with the server, returns {"loggedOut": "true"} or the users profile object

user.remote(remoteDbName)

returns a multilevel sublevel instance hooked up over a binary websocket to the level-socket backend.

user.copy(from, to, cb)

pipes all data from from into to, overwriting any existing records in to.

example usage:

var user = require('level-user')({dbName: 'blocks', baseURL: "http://localhost:8080" })
var local = user.db.sublevel('foo')
var remote = user.remote('foo')
user.copy(remote, local, function(err) {
  
})

TODO more docs

license

BSD

FAQs

Package last updated on 10 Aug 2013

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