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

@polybase/client

Package Overview
Dependencies
Maintainers
3
Versions
94
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@polybase/client

Client (browser/node) for Polybase

latest
npmnpm
Version
0.6.6
Version published
Weekly downloads
87
14.47%
Maintainers
3
Weekly downloads
 
Created
Source

Polybase Client (Browser/Node)

A client to connect to the Polybase decentralized database.

Install Polybase

npm install @polybase/client
yarn add @polybase/client

Initialize the SDK

import Polybase from '@polybase/client'

const db = new Polybase({
  ...config
})

Get a single record

You can read data once, by calling the .record(id: string).get() method on a collection.

const colRef = db.collection("org/places")
const record = await colRef.record("id").get()

const { id, ...data } = record

Write data

const colRef = db.collection("org/places")
const record = await colRef.record("london").call("setName", ["Name"])

Tests

To run E2E tests, ensure that Polybase is running, and then run:

yarn test:e2e

FAQs

Package last updated on 23 Aug 2023

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