package
MongoDB persistent storage adapter for Harō
npm install haro-mongoGitHub-flavored package documentation.
Across all versions.
Download trend unavailable.
Runtime metadata.
Tagged topics.
Harō is a modern immutable DataStore built with ES6 features, which can be wired to an API for a complete feedback loop.
It is un-opinionated, and offers a plug'n'play solution to modeling, searching, & managing data on the client, or server
(in RAM). It is a partially persistent data structure, by maintaining version sets of records in versions (MVCC).
haro-mongo is a persistent storage adapter, providing 'auto saving' behavior, as well as the ability to save() & load() the entire DataStore.
If store.key is not set, the fail over "id" field will be id.
Require the adapter & register it with haro.register(key, fn). The key must match the store.adapters key.
const haro = require('haro'),
store = haro(null, {adapters: {mongo: "mongodb://localhost/mydb"}});
// Register the adapter
store.register('mongo', require('haro-mongo'));
// Ready to `load()`, `batch()` or `set()`!Copyright (c) 2019 Jason Mulligan Licensed under the BSD-3 license
Estimated unpacked size across 8 packages.
6.3 MB
Includes dependencies.