{"name":"datastore-core","version":"5.0.1","description":"Wrapper implementation for interface-datastore","leadMaintainer":"Alex Potsides <alex.potsides@protocol.ai>","main":"src/index.js","types":"dist/src/index.d.ts","scripts":{"prepare":"aegir build --no-bundle","test":"aegir test","test:node":"aegir test -t node","test:browser":"aegir test -t browser","test:webworker":"aegir test -t webworker","lint":"aegir lint","release":"aegir release","release-minor":"aegir release --type minor","release-major":"aegir release --type major","coverage":"nyc -s npm run test:node && nyc report --reporter=html","dep-check":"aegir dep-check"},"repository":{"type":"git","url":"git+https://github.com/ipfs/js-datastore-core.git"},"keywords":["interface","key-value","ipfs","datastore"],"author":{"name":"Friedel Ziegelmayer","email":"dignifiedquire@gmail.com"},"license":"MIT","bugs":{"url":"https://github.com/ipfs/js-datastore-core/issues"},"homepage":"https://github.com/ipfs/js-datastore-core#readme","devDependencies":{"@types/debug":"^4.1.5","aegir":"^33.1.0","interface-datastore-tests":"^1.0.0","it-all":"^1.0.4"},"dependencies":{"debug":"^4.1.1","interface-datastore":"^5.1.1","it-drain":"^1.0.4","it-filter":"^1.0.2","it-map":"^1.0.5","it-merge":"^1.0.1","it-pipe":"^1.1.0","it-pushable":"^1.4.2","it-take":"^1.0.1","uint8arrays":"^2.1.5"},"engines":{"node":">=12.0.0"},"eslintConfig":{"extends":"ipfs"},"contributors":[{"name":"achingbrain","email":"alex@achingbrain.net"},{"name":"David Dias","email":"daviddias.p@gmail.com"},{"name":"Friedel Ziegelmayer","email":"dignifiedquire@gmail.com"},{"name":"Hugo Dias","email":"hugomrdias@gmail.com"},{"name":"Hector Sanjuan","email":"code@hector.link"},{"name":"Zane Starr","email":"zcstarr@zaner.attlocal.net"},{"name":"Jacob Heun","email":"jacobheun@gmail.com"},{"name":"ᴠɪᴄᴛᴏʀ ʙᴊᴇʟᴋʜᴏʟᴍ","email":"victorbjelkholm@gmail.com"},{"name":"Pedro Teixeira","email":"i@pgte.me"},{"name":"Bryan Stenson","email":"bryan.stenson@gmail.com"},{"name":"Richard Schneider","email":"makaretu@gmail.com"},{"name":"Vasco Santos","email":"vasco.santos@moxy.studio"}],"gitHead":"3335f82532a34e9c9a36ba340d8b9078ddc83a4c","_id":"datastore-core@5.0.1","_nodeVersion":"14.16.0","_npmVersion":"6.14.11","dist":{"integrity":"sha512-71CfpshtiV9VeolcUagLP4qxJ5xJLulHD1snyH3p3lO/XJZFsXp71gvoIokrLnTkecwHDvaaNIe5gMt+cnSCgQ==","shasum":"1b68fd8f5c376ddabd4854bb7ee59ca677c36895","tarball":"http://registry-npm.ywwl.com/datastore-core/download/datastore-core-5.0.1.tgz","fileCount":31,"unpackedSize":56082,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJg+vKDCRA9TVsSAnZWagAA5XMP/300VH1Fm1X/mI4ZPxGS\nwC9ZbabQnOONXLZJ0T+8cSV5uv14biVpkdYXRgw2hpe8z4WwuZ0s8snmkpfc\nnbGBMroHdtvIKHnxWZm4wV9Ku3qM/Tj9d3kf50hh6Acgp/5kyp9G08WKgQpR\nbW7n6UxdnSbGgi3XEScrXE65pjZ1CEo8LpfjwkUteLDeemrtLzViVCjrF0ys\nuMt82v/4I388/SyMjGcD5YBOSl+K7WFdrjG5wgVhGKeMMTHHP8RLHJMK7fej\nHR7ky8ZqdCGrxWcc6/Urn5FjWif+TnXInSC05FVOhJ//4/kSm+8aiEJs+ay4\nRYtLI0hlcXGuWDA4E20/4spVmAhwbFyos3cIDhNm9DtW1kPiSOk7PfmAtzKl\nVzthHM+hrT2XR9cN6k1H33U1V5cXxf4eBI9uwPFr7nCf4eLOzN8ghjHKWMSP\nlwe5WiACazj8utzRXO9xkLcKkugWZx0jb87uD4CiHMBMYU4h9mKduW7qtIgR\ntlHyUtNad8qu+WMJwOz7xzM2+aCJYCm3d0EQCgsfR4z9hcbljCEnhYqiWizg\n5kjtJ1bqLQsgMOi6igBdwnZgZBB92bdtCvJSvUi3s4F97FhEJZ7DDTW0B0bL\naFIuQtGC1Pt7TGk9QVvZu6BO2qfx1Elh0H/xEt7RyFqaga0KMbtbkiI3WCmC\naupg\r\n=apuW\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICXO+HplzZ5Etqr2St+6UtqUptE3Re58F7i1mvsO1z0PAiAUAKVHc8ewOO1lzNC8uDDnpV6NxjnLaHKIFproMbEyTg=="}],"size":13226,"noattachment":false,"key":"/datastore-core/-/datastore-core-5.0.1.tgz"},"_npmUser":{"name":"achingbrain","email":"alex@achingbrain.net"},"directories":{},"maintainers":[{"name":"daviddias","email":"mail@daviddias.me"},{"name":"dignifiedquire","email":"dignifiedquire@gmail.com"},{"name":"achingbrain","email":"alex@achingbrain.net"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/datastore-core_5.0.1_1627058819810_0.17058229104479006"},"_hasShrinkwrap":false,"readme":"# datastore-core\n\n[![ipfs.tech](https://img.shields.io/badge/project-IPFS-blue.svg?style=flat-square)](https://ipfs.tech)\n[![Discuss](https://img.shields.io/discourse/https/discuss.ipfs.tech/posts.svg?style=flat-square)](https://discuss.ipfs.tech)\n[![codecov](https://img.shields.io/codecov/c/github/ipfs/js-stores.svg?style=flat-square)](https://codecov.io/gh/ipfs/js-stores)\n[![CI](https://img.shields.io/github/actions/workflow/status/ipfs/js-stores/js-test-and-release.yml?branch=main\\&style=flat-square)](https://github.com/ipfs/js-stores/actions/workflows/js-test-and-release.yml?query=branch%3Amain)\n\n> Wrapper implementation for interface-datastore\n\n# About\n\n<!--\n\n!IMPORTANT!\n\nEverything in this README between \"# About\" and \"# Install\" is automatically\ngenerated and will be overwritten the next time the doc generator is run.\n\nTo make changes to this section, please update the @packageDocumentation section\nof src/index.js or src/index.ts\n\nTo experiment with formatting, please run \"npm run docs\" from the root of this\nrepo and examine the changes made.\n\n-->\n\nVarious Datastore implementations are available.\n\n## Implementations\n\n- Mount: [`src/mount`](src/mount.ts)\n- Keytransform: [`src/keytransform`](src/keytransform.ts)\n- Sharding: [`src/sharding`](src/sharding.ts)\n- Tiered: [`src/tiered`](src/tirered.ts)\n- Namespace: [`src/namespace`](src/namespace.ts)\n- BlackHole: [`src/black-hole`](src/black-hole.ts)\n\n## Example - BaseDatastore\n\nAn base store is made available to make implementing your own datastore easier:\n\n```javascript\nimport { BaseDatastore } from 'datastore-core'\n\nclass MyDatastore extends BaseDatastore {\n  constructor () {\n    super()\n  }\n\n  async put (key, val) {\n    // your implementation here\n  }\n\n  async get (key) {\n    // your implementation here\n  }\n\n  // etc...\n}\n```\n\nSee the [MemoryDatastore](./src/memory.js) for an example of how it is used.\n\n## Example - Wrapping Stores\n\n```js\nimport { Key } from 'interface-datastore'\nimport {\n  MemoryStore,\n  MountStore\n} from 'datastore-core'\n\nconst store = new MountStore({prefix: new Key('/a'), datastore: new MemoryStore()})\n```\n\n## Example - BlackHoleDatastore\n\nA datastore that does not store any data.\n\n```js\nimport { BlackHoleDatastore } from 'datastore-core/black-hole'\n\nconst store = new BlackHoleDatastore()\n```\n\n# Install\n\n```console\n$ npm i datastore-core\n```\n\n## Browser `<script>` tag\n\nLoading this module through a script tag will make it's exports available as `DatastoreCore` in the global namespace.\n\n```html\n<script src=\"https://unpkg.com/datastore-core/dist/index.min.js\"></script>\n```\n\n# API Docs\n\n- <https://ipfs.github.io/js-stores/modules/datastore_core.html>\n\n# License\n\nLicensed under either of\n\n- Apache 2.0, ([LICENSE-APACHE](LICENSE-APACHE) / <http://www.apache.org/licenses/LICENSE-2.0>)\n- MIT ([LICENSE-MIT](LICENSE-MIT) / <http://opensource.org/licenses/MIT>)\n\n# Contribute\n\nContributions welcome! Please check out [the issues](https://github.com/ipfs/js-stores/issues).\n\nAlso see our [contributing document](https://github.com/ipfs/community/blob/master/CONTRIBUTING_JS.md) for more information on how we work, and about contributing in general.\n\nPlease be aware that all interactions related to this repo are subject to the IPFS [Code of Conduct](https://github.com/ipfs/community/blob/master/code-of-conduct.md).\n\nUnless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.\n\n[![](https://cdn.rawgit.com/jbenet/contribute-ipfs-gif/master/img/contribute.gif)](https://github.com/ipfs/community/blob/master/CONTRIBUTING.md)\n","publish_time":1627058819960,"_cnpm_publish_time":1627058819960,"dist-tags":{"latest":"12.0.1"}}