{"id":20630701,"url":"https://github.com/sysgears/apollo-cache-logger","last_synced_at":"2025-04-15T18:22:39.889Z","repository":{"id":57182286,"uuid":"130229594","full_name":"sysgears/apollo-cache-logger","owner":"sysgears","description":"Apollo Cache Logger","archived":false,"fork":false,"pushed_at":"2018-04-30T16:59:16.000Z","size":17,"stargazers_count":6,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-04T17:48:57.028Z","etag":null,"topics":["apollo","apollo-client","graphql"],"latest_commit_sha":null,"homepage":null,"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/sysgears.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":"2018-04-19T14:38:17.000Z","updated_at":"2021-06-01T16:38:52.000Z","dependencies_parsed_at":"2022-09-14T06:01:47.141Z","dependency_job_id":null,"html_url":"https://github.com/sysgears/apollo-cache-logger","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/sysgears%2Fapollo-cache-logger","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sysgears%2Fapollo-cache-logger/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sysgears%2Fapollo-cache-logger/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sysgears%2Fapollo-cache-logger/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sysgears","download_url":"https://codeload.github.com/sysgears/apollo-cache-logger/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249126451,"owners_count":21216785,"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":["apollo","apollo-client","graphql"],"created_at":"2024-11-16T14:09:19.653Z","updated_at":"2025-04-15T18:22:39.865Z","avatar_url":"https://github.com/sysgears.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Apollo Cache Logger\n\n[![npm version](https://badge.fury.io/js/apollo-cache-logger.svg)](https://badge.fury.io/js/apollo-cache-logger)\n[![Twitter Follow](https://img.shields.io/twitter/follow/sysgears.svg?style=social)](https://twitter.com/sysgears)\n\n## Installation\n\n```bash\nnpm install --save-dev apollo-cache-logger\n```\n\n## Usage\n``` js\nimport LogCache from 'apollo-cache-logger';\n\nconst cache = new LogCache(new InMemoryCache(), { logger: msg =\u003e console.log(msg) });\n```\n\nSample output:\n\n``` js\nread(query CounterState {\n  counterState @client {\n    counter\n  }\n}) -\u003e {\"counterState\":{\"counter\":1,\"__typename\":\"CounterState\"}}\ndiff(query CounterState {\n  counterState @client {\n    counter\n    __typename\n  }\n}) -\u003e {\"result\":{\"counterState\":{\"counter\":1,\"__typename\":\"CounterState\"}},\"complete\":true}\nread(query counterQuery {\n  counter {\n    amount\n  }\n}) -\u003e {\"counter\":{\"amount\":19,\"__typename\":\"Counter\"}}\n```\n### Routing\nIf you want to manage several Apollo Caches separately and route between them on a GraphQL document-basis please check [`apollo-cache-router`](https://github.com/sysgears/apollo-cache-router)\n\n## License\nCopyright © 2018 [SysGears LTD]. This source code is licensed under the [MIT] license.\n\n[MIT]: LICENSE\n[SysGears LTD]: http://sysgears.com\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsysgears%2Fapollo-cache-logger","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsysgears%2Fapollo-cache-logger","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsysgears%2Fapollo-cache-logger/lists"}