{"id":24918181,"url":"https://github.com/dev-siri/reactivity-stores","last_synced_at":"2025-03-28T08:40:41.678Z","repository":{"id":187486562,"uuid":"677102468","full_name":"Dev-Siri/reactivity-stores","owner":"Dev-Siri","description":"Simple TypeScript-first state management with reactive stores.","archived":false,"fork":false,"pushed_at":"2023-08-12T08:57:47.000Z","size":11,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-10-11T00:33:04.460Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/Dev-Siri.png","metadata":{"files":{"readme":"README.md","changelog":null,"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":"2023-08-10T18:37:28.000Z","updated_at":"2023-08-10T18:39:17.000Z","dependencies_parsed_at":"2024-09-30T12:30:24.908Z","dependency_job_id":"28c85b8b-0cc7-4d97-8d1b-2672c2b524d8","html_url":"https://github.com/Dev-Siri/reactivity-stores","commit_stats":{"total_commits":7,"total_committers":1,"mean_commits":7.0,"dds":0.0,"last_synced_commit":"38d5c31a38a7c87549ef3cbd77f3ca608319017d"},"previous_names":["dev-siri/reactivity-stores"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dev-Siri%2Freactivity-stores","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dev-Siri%2Freactivity-stores/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dev-Siri%2Freactivity-stores/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Dev-Siri%2Freactivity-stores/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Dev-Siri","download_url":"https://codeload.github.com/Dev-Siri/reactivity-stores/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245999332,"owners_count":20707554,"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":"2025-02-02T09:18:59.503Z","updated_at":"2025-03-28T08:40:41.655Z","avatar_url":"https://github.com/Dev-Siri.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Reactive Stores\n\nReactive is a powerful tool for managing application state in a reactive and efficient manner. It provides a clean and organized way to handle global state, reactivity, and state updates.\n\n## Installation\n\nYou can install the library using your preferred package manager:\n\n```bash\npnpm add reactive-stores\n```\n\n## Usage\n\nImport the library and start using it to manage your application's state. Here's a simple example of how you might use the library:\n\n```ts\n// Type modules for end-to-end type safety\nimport Store, { mergeStores, type State } from \"reactive-stores\";\n\n// Create stores\nconst counterStore = new Store(\"counter-store\", { count: 0 });\nconst inputStore = new Store(\"input-store\", {\n  email: \"hello@example.com\",\n  password: \"********\",\n});\n\n// Merge stores\nconst mergedStore = mergeStores\u003c{\n  \"counter-store\": State\u003ctypeof counterStore\u003e;\n  \"input-store\": State\u003ctypeof inputStore\u003e;\n}\u003e(\"merged-store\", [counterStore, inputStore]);\n\n// Subscribe to stores\nconst currentCount = counterStore.subscribe((count) =\u003e\n  console.log(\"Current count:\", count)\n);\n\n// and update it\ncounterStore.set({ count: (prevCount) =\u003e ++prevCount });\n```\n\n## Features\n\n- **Global State Management:** Manage global application state that can be accessed and updated from different components.\n\n- **Reactivity:** Automatically update components when the state changes, reducing manual handling and improving consistency.\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdev-siri%2Freactivity-stores","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdev-siri%2Freactivity-stores","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdev-siri%2Freactivity-stores/lists"}