{"id":17056389,"url":"https://github.com/eneajaho/observable-store","last_synced_at":"2025-10-23T17:16:40.683Z","repository":{"id":38545804,"uuid":"264459324","full_name":"eneajaho/observable-store","owner":"eneajaho","description":"An observable store built with rxjs, ideal for small/medium projects.","archived":false,"fork":false,"pushed_at":"2023-01-07T18:16:14.000Z","size":2187,"stargazers_count":15,"open_issues_count":27,"forks_count":3,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-06T05:16:54.664Z","etag":null,"topics":["angular","rxjs","store"],"latest_commit_sha":null,"homepage":"https://github.com/eneajaho/observable-store/tree/master/src/app/store","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/eneajaho.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}},"created_at":"2020-05-16T14:50:00.000Z","updated_at":"2024-10-15T00:45:24.000Z","dependencies_parsed_at":"2023-02-07T20:00:19.908Z","dependency_job_id":null,"html_url":"https://github.com/eneajaho/observable-store","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eneajaho%2Fobservable-store","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eneajaho%2Fobservable-store/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eneajaho%2Fobservable-store/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eneajaho%2Fobservable-store/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/eneajaho","download_url":"https://codeload.github.com/eneajaho/observable-store/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248603566,"owners_count":21131819,"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":["angular","rxjs","store"],"created_at":"2024-10-14T10:24:17.851Z","updated_at":"2025-10-23T17:16:35.618Z","avatar_url":"https://github.com/eneajaho.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Run Project Locally - [Live project][https://observable-store.eneajaho.me/]\n\n**Install node modules**\n```bash\nnpm install\n```\n\n**Start Angular app**\n```bash\nng s -o\n```\n\n**Start json-server**\n```bash\njson-server --watch db.json\n```\n\n### What's included\n- Smart components (Containers)\n- Dumb components (Presenters)\n- Lazy loading modules\n- Reactive forms\n- Interceptors\n- Resolvers\n- Services\n- Facades\n- Guards\n- Pipes\n- Models\n- **Observable Store** - [Docs](https://github.com/eneajaho/observable-store/blob/master/src/app/store/README.md)\n\n\n### CRUD data in services or components\n```js\n  constructor(private http: HttpClient, private store: Store) { }\n \n  getFavorites(): Observable\u003c{ id: number }[]\u003e {\n    return this.http.get\u003c{ id: number }[]\u003e(`${this.api}/favorites`)\n      .pipe(tap(res =\u003e this.store.set('favorites', res)));\n  }\n\n  addFavorite(id: number): Observable\u003cany\u003e {\n    return this.http.post(`${this.api}/favorites`, { id }).pipe(\n      tap(() =\u003e this.store.setItem('favorites', id, { id }))\n    );\n  }\n\n  removeFavorite(id: number): Observable\u003cany\u003e {\n    return this.http.delete(`${this.api}/favorites/${id}`).pipe(\n      tap(() =\u003e this.store.removeItem('favorites', id))\n    );\n  }\n```\n\n### Getting data from store\n```js\n  movies$: Observable\u003cMovie[]\u003e;\n  favorites$: Observable\u003cFavorite[]\u003e;\n\n  constructor(private store: Store) { }\n\n  ngOnInit() {\n    this.movies$ = this.store.select\u003cMovie[]\u003e('movies');\n    this.favorites$ = this.store.select\u003cFavorite[]\u003e('favorites');\n  }\n```\n\n### Screenshot\n![Movies Store](https://i.imgur.com/WWKVb3X.jpg)\n\n[https://observable-store.eneajaho.me/]: https://observable-store.eneajaho.me/\n\n\n---\n\n\u003e License: **MIT**\n\n\u003e Author: **Enea Jahollari** \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feneajaho%2Fobservable-store","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feneajaho%2Fobservable-store","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feneajaho%2Fobservable-store/lists"}