{"id":15152894,"url":"https://github.com/ipfs/js-datastore-level","last_synced_at":"2025-09-30T01:31:26.818Z","repository":{"id":18692177,"uuid":"84766182","full_name":"ipfs/js-datastore-level","owner":"ipfs","description":"Datastore implementation with level(up/down) backend","archived":true,"fork":false,"pushed_at":"2023-03-23T17:04:19.000Z","size":1582,"stargazers_count":19,"open_issues_count":0,"forks_count":15,"subscribers_count":25,"default_branch":"master","last_synced_at":"2024-10-29T11:33:37.775Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ipfs.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-03-12T23:53:14.000Z","updated_at":"2023-10-13T00:04:12.000Z","dependencies_parsed_at":"2024-08-05T16:11:39.673Z","dependency_job_id":null,"html_url":"https://github.com/ipfs/js-datastore-level","commit_stats":{"total_commits":176,"total_committers":22,"mean_commits":8.0,"dds":0.6193181818181819,"last_synced_commit":"f84aa940047d9fd06ac6759a96d842d5930ca08c"},"previous_names":[],"tags_count":39,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ipfs%2Fjs-datastore-level","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ipfs%2Fjs-datastore-level/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ipfs%2Fjs-datastore-level/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ipfs%2Fjs-datastore-level/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ipfs","download_url":"https://codeload.github.com/ipfs/js-datastore-level/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":230480457,"owners_count":18232721,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-09-26T16:41:16.406Z","updated_at":"2025-09-30T01:31:21.555Z","avatar_url":"https://github.com/ipfs.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ⛔️ This module is now part of https://github.com/ipfs/js-stores\n\n# datastore-level \u003c!-- omit in toc --\u003e\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-datastore-level.svg?style=flat-square)](https://codecov.io/gh/ipfs/js-datastore-level)\n[![CI](https://img.shields.io/github/actions/workflow/status/ipfs/js-datastore-level/js-test-and-release.yml?branch=master\\\u0026style=flat-square)](https://github.com/ipfs/js-datastore-level/actions/workflows/js-test-and-release.yml?query=branch%3Amaster)\n\n\u003e Datastore implementation with level(up|down) backend\n\n## Table of contents \u003c!-- omit in toc --\u003e\n\n- [Install](#install)\n  - [Browser `\u003cscript\u003e` tag](#browser-script-tag)\n- [Usage](#usage)\n  - [Browser Shimming Leveldown](#browser-shimming-leveldown)\n  - [Database names](#database-names)\n- [License](#license)\n- [Contribute](#contribute)\n\n## Install\n\n```console\n$ npm i datastore-level\n```\n\n### Browser `\u003cscript\u003e` tag\n\nLoading this module through a script tag will make it's exports available as `DatastoreLevel` in the global namespace.\n\n```html\n\u003cscript src=\"https://unpkg.com/datastore-level/dist/index.min.js\"\u003e\u003c/script\u003e\n```\n\n## Usage\n\n```js\nimport { LevelDatastore } from 'datastore-level'\n\n// Default using level as backend for node or the browser\nconst store = new LevelDatastore('path/to/store')\n\n// another leveldown compliant backend like memory-level\nconst memStore = new LevelDatastore(\n  new MemoryLevel({\n    keyEncoding: 'utf8',\n    valueEncoding: 'view'\n  })\n)\n```\n\n### Browser Shimming Leveldown\n\n`LevelStore` uses the `level` module to automatically use `level` if a modern bundler is used which can detect bundle targets based on the `pkg.browser` property in your `package.json`.\n\nIf you are using a bundler that does not support `pkg.browser`, you will need to handle the shimming yourself, as was the case with versions of `LevelStore` 0.7.0 and earlier.\n\n### Database names\n\n`level-js@3` changed the database prefix from `IDBWrapper-` to `level-js-`, so please specify the old prefix if you wish to continue using databases created using `datastore-level` prior to `v0.12.0`.  E.g.\n\n```javascript\nimport leveljs from 'level-js'\nimport browserStore = new LevelDatastore(\n  new Level('my/db/name', {\n    prefix: 'IDBWrapper-'\n  })\n})\n```\n\nMore information: [https://github.com/Level/level-js/blob/master/UPGRADING.md#new-database-prefix](https://github.com/Level/level-js/blob/99831913e905d19e5f6dee56d512b7264fbed7bd/UPGRADING.md#new-database-prefix)\n\n## License\n\nLicensed under either of\n\n- Apache 2.0, ([LICENSE-APACHE](LICENSE-APACHE) / \u003chttp://www.apache.org/licenses/LICENSE-2.0\u003e)\n- MIT ([LICENSE-MIT](LICENSE-MIT) / \u003chttp://opensource.org/licenses/MIT\u003e)\n\n## Contribute\n\nContributions welcome! Please check out [the issues](https://github.com/ipfs/js-datastore-level/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","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fipfs%2Fjs-datastore-level","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fipfs%2Fjs-datastore-level","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fipfs%2Fjs-datastore-level/lists"}