{"id":24075490,"url":"https://github.com/vasilyvp/kv-structures","last_synced_at":"2025-04-30T05:04:27.981Z","repository":{"id":267736171,"uuid":"902176724","full_name":"VasilyVP/kv-structures","owner":"VasilyVP","description":"JavaScript data structures for various storage engines","archived":false,"fork":false,"pushed_at":"2025-02-19T16:58:35.000Z","size":172,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-30T05:04:18.227Z","etag":null,"topics":["data-structures","javascript","redis"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/VasilyVP.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2024-12-12T04:00:39.000Z","updated_at":"2025-04-05T00:33:48.000Z","dependencies_parsed_at":"2024-12-12T06:19:53.845Z","dependency_job_id":"574418a8-0e0e-4dc7-be4c-18388ae639ce","html_url":"https://github.com/VasilyVP/kv-structures","commit_stats":null,"previous_names":["vasilyvp/structured","vasilyvp/kv-structures","kv-structures/kv-structures"],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VasilyVP%2Fkv-structures","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VasilyVP%2Fkv-structures/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VasilyVP%2Fkv-structures/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VasilyVP%2Fkv-structures/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/VasilyVP","download_url":"https://codeload.github.com/VasilyVP/kv-structures/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251644842,"owners_count":21620632,"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":["data-structures","javascript","redis"],"created_at":"2025-01-09T19:05:19.934Z","updated_at":"2025-04-30T05:04:27.975Z","avatar_url":"https://github.com/VasilyVP.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# @kv-structures\n\n## Overview\n\n`@kv-structures` is a repository of packages to provide native JavaScript data structures (`Map`, `Set`, etc.) for use with various storage engines. The goal of this repository is to offer an abstraction layer that allows developers to interact with different storage backends in the same way they would with built-in JavaScript structures, like `Map` or `Set`.\n\nThis package aims to create a seamless experience where you can store and retrieve data using familiar JavaScript APIs while leveraging the strengths of various storage systems, including Redis, DynamoDB, and more.\n\n## Key Features\n\n- **Unified API**: Interact with data structures like `Map`, `Set`, and others across different storage engines.\n- **Flexible Storage Backends**: Start with Redis and expand to other engines like Cloudflare KV, and more.\n- **Seamless Integration**: Easily integrate Redis-backed data structures (such as `RedisMap` and `RedisSet`) into your application.\n- **Future-proof**: The library will grow to support more storage backends, providing the same intuitive API for each.\n\n## Installation\n\nTo install the whole package, add to the `.npmrc`\n```bash\n@vasilyvp:registry=https://npm.pkg.github.com/\n```\n\nand run:\n\n```bash\nnpm install @vasilyvp/kv-structures\n```\n## Usage\n\n```typescript\nimport { redisInit, redisQuit, RedisMap } from '@vasilyvp/kv-structures';\n\nawait redisInit(); // Call this method once at the start of the app\n\nconst map = new RedisMap\u003cstring\u003e('myMap', 60000); // Name and optional TTL (in ms)\n\nawait map.set('myKey', 'myValue');\nconst value = await map.get('myKey'); // 'myValue'\n\nawait redisQuit();\n```\n\nRefer to the specific engine's documentation for more details.\n\n## Available specific engines\n### [`@kv-structures/redis`](https://github.com/vasilyvp/kv-structures/tree/main/packages/redis)\n\nThis package is a Redis-specific package that implements Redis-backed data structures for use in JavaScript applications. You can think of [`@kv-structures/redis`](https://github.com/vasilyvp/kv-structures/tree/main/packages/redis) as one of the engines available through `@kv-structures`.\n\n## License\n\nThis project is licensed under the [ISC License](https://opensource.org/licenses/ISC).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvasilyvp%2Fkv-structures","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvasilyvp%2Fkv-structures","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvasilyvp%2Fkv-structures/lists"}