npm.io
12.4.2 • Published 7 years ago

@dstaley/kinto

Licence
Apache-2.0
Version
12.4.2
Deps
7
Size
593 kB
Vulns
1
Weekly
0
Stars
331

Kinto.js

Greenkeeper badge

Build Status Coverage Status

An Offline-First JavaScript client for Kinto.

Note: If you're looking for a pure HTTP js client for Kinto, check out kinto-http.js.

The idea is to persist data locally in the browser by default, then synchronizing them with the server explicitly when connectivity is guaranteed:

const kinto = new Kinto({remote: "https://kinto.dev.mozaws.net/v1/"});
const posts = kinto.collection("posts");

// Create and store a new post in the browser local database
await posts.create({title: "first post"});

// Publish all local data to the server, import remote changes
await posts.sync();

Documentation

Keywords