{"_id":"@csark0812/zustand-getters","_rev":"9-722217fc8d496fc18be707cfdf86cd6b","name":"@csark0812/zustand-getters","dist-tags":{"latest":"1.0.10"},"versions":{"1.0.0":{"name":"@csark0812/zustand-getters","version":"1.0.0","keywords":["zustand","middleware","state","getters","reactive","derived-state","computed","react","state-management","javascript-getters"],"author":{"name":"Christopher Sarkissian"},"license":"MIT","_id":"@csark0812/zustand-getters@1.0.0","maintainers":[{"name":"csark0812","email":"csark0812@gmail.com"}],"homepage":"https://github.com/csark0812/zustand-getters#readme","bugs":{"url":"https://github.com/csark0812/zustand-getters/issues"},"dist":{"shasum":"b5a407e6ca066a4cb65e8ce9852b4b91f37e5278","tarball":"https://registry.npmjs.org/@csark0812/zustand-getters/-/zustand-getters-1.0.0.tgz","fileCount":7,"integrity":"sha512-bL6kdqwYHT2BBoE2L9MQTxSCSWEUOswh69mFh+fOyP7CYLlJrRUj8rUPhpZA+DQcvEgSilh6jaiF+Q8IkiF//w==","signatures":[{"sig":"MEUCIQDqWvsSoG8awuhrHe3PEYTJv1xozEvs6egQl6GyrpRUfwIgb1sH9g9ffNkj/W5fLAOGHDb+unUgdkbXOhmJkMQVBfc=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":23213},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/index.cjs"}},"gitHead":"5bcf9f55c3eaf5ef9a32b379c24fe2257f19e28d","scripts":{"dev":"vite build --watch","lint":"eslint . --fix","test":"bun run build && bun run test.ts","build":"vite build && tsc --emitDeclarationOnly --declaration --outDir dist","format":"prettier . --write","example":"cd example && bun run dev","typecheck":"tsc --noEmit"},"_npmUser":{"name":"csark0812","email":"csark0812@gmail.com"},"prettier":{"semi":true,"tabWidth":2,"printWidth":100,"arrowParens":"always","singleQuote":true,"trailingComma":"all","bracketSpacing":true},"repository":{"url":"git+https://github.com/csark0812/zustand-getters.git","type":"git"},"_npmVersion":"11.4.2","description":"A Zustand middleware that makes regular JavaScript object getters reactive","directories":{},"_nodeVersion":"24.4.1","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"vite":"^5.0.0","react":"^19.2.3","eslint":"^9.17.0","zustand":"^5.0.0","prettier":"^3.6.2","typescript":"^5.3.0","@types/node":"^22.0.0","eslint-config-prettier":"^10.1.5","eslint-plugin-prettier":"^5.5.1","@typescript-eslint/parser":"^8.0.0","@typescript-eslint/eslint-plugin":"^8.0.0"},"peerDependencies":{"zustand":"^4.0.0 || ^5.0.0"},"_npmOperationalInternal":{"tmp":"tmp/zustand-getters_1.0.0_1766133929165_0.26367493239527096","host":"s3://npm-registry-packages-npm-production"}},"1.0.3":{"name":"@csark0812/zustand-getters","version":"1.0.3","keywords":["zustand","middleware","state","getters","reactive","derived-state","computed","react","state-management","javascript-getters"],"author":{"name":"Christopher Sarkissian"},"license":"MIT","_id":"@csark0812/zustand-getters@1.0.3","maintainers":[{"name":"csark0812","email":"csark0812@gmail.com"}],"homepage":"https://github.com/csark0812/zustand-getters#readme","bugs":{"url":"https://github.com/csark0812/zustand-getters/issues"},"dist":{"shasum":"cf8bc177b5d16a2cc4729baa588f7e89c2a8b26a","tarball":"https://registry.npmjs.org/@csark0812/zustand-getters/-/zustand-getters-1.0.3.tgz","fileCount":7,"integrity":"sha512-zlvl1HqfrCShEYfFg9se3fukcRTIMRuzWIxIWDj+LleV9pTHpJ/rkKGNFdNDfph3ZH7yIP5Hpl+Wj9HbN2X1Iw==","signatures":[{"sig":"MEUCIQD0sAX+8zfwwSBFwTCy/AqaDWFECb3qyZqXu0g8m5uGJAIgdCSelrNrKyIqXcyDchnsX8L0w4J9MozRQP3eQgm2jqE=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@csark0812%2fzustand-getters@1.0.3","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":23249},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/index.cjs"}},"gitHead":"8d77394a24815186ad40f57dbae3525d7ce138fb","scripts":{"dev":"vite build --watch","lint":"eslint . --fix","test":"bun run build && bun run test.ts","build":"vite build && tsc --emitDeclarationOnly --declaration --outDir dist","format":"prettier . --write","example":"cd example && bun run dev","typecheck":"tsc --noEmit"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:1767fb99-c08c-45d4-8697-f832d34bf603"}},"prettier":{"semi":true,"tabWidth":2,"printWidth":100,"arrowParens":"always","singleQuote":true,"trailingComma":"all","bracketSpacing":true},"repository":{"url":"git+https://github.com/csark0812/zustand-getters.git","type":"git"},"_npmVersion":"11.7.0","description":"A Zustand middleware that makes regular JavaScript object getters reactive","directories":{},"_nodeVersion":"20.19.6","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"vite":"^5.0.0","react":"^19.2.3","eslint":"^9.17.0","zustand":"^5.0.0","prettier":"^3.6.2","typescript":"^5.3.0","@types/node":"^22.0.0","typescript-eslint":"^8.50.0","eslint-config-prettier":"^10.1.5","eslint-plugin-prettier":"^5.5.1","@typescript-eslint/parser":"^8.0.0","@typescript-eslint/eslint-plugin":"^8.0.0"},"peerDependencies":{"zustand":"^4.0.0 || ^5.0.0"},"_npmOperationalInternal":{"tmp":"tmp/zustand-getters_1.0.3_1766134522265_0.4304025191751233","host":"s3://npm-registry-packages-npm-production"}},"1.0.4":{"name":"@csark0812/zustand-getters","version":"1.0.4","keywords":["zustand","middleware","state","getters","reactive","derived-state","computed","react","state-management","javascript-getters"],"author":{"name":"Christopher Sarkissian"},"license":"MIT","_id":"@csark0812/zustand-getters@1.0.4","maintainers":[{"name":"csark0812","email":"csark0812@gmail.com"}],"homepage":"https://github.com/csark0812/zustand-getters#readme","bugs":{"url":"https://github.com/csark0812/zustand-getters/issues"},"dist":{"shasum":"dbf3d64dba3af9171ca7d1d5b5f83930ae8de766","tarball":"https://registry.npmjs.org/@csark0812/zustand-getters/-/zustand-getters-1.0.4.tgz","fileCount":7,"integrity":"sha512-oxNmdOSpBiO+nLhZ7Svm+sH7RWsxCsS9tHOZ8wXHVZkIs5QY5sv1McDaIBhzcIne3vwR9Js2z1gxEjhY/b1GPA==","signatures":[{"sig":"MEYCIQCY2xS+705JPDxCHOyjU8fawPxps0Yqkk7VpglXTjylIgIhALAWun9FVBHlZZVDCkRw2KB13sqWjhGnODFuVI1L8Iqu","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@csark0812%2fzustand-getters@1.0.4","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":23249},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/index.cjs"}},"gitHead":"ce298b166aa42a6e4f308f041e44751635326718","scripts":{"dev":"vite build --watch","lint":"eslint . --fix","test":"bun run build && bun run test.ts","build":"vite build && tsc --emitDeclarationOnly --declaration --outDir dist","format":"prettier . --write","example":"cd example && bun run dev","typecheck":"tsc --noEmit"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:1767fb99-c08c-45d4-8697-f832d34bf603"}},"prettier":{"semi":true,"tabWidth":2,"printWidth":100,"arrowParens":"always","singleQuote":true,"trailingComma":"all","bracketSpacing":true},"repository":{"url":"git+https://github.com/csark0812/zustand-getters.git","type":"git"},"_npmVersion":"11.7.0","description":"A Zustand middleware that makes regular JavaScript object getters reactive","directories":{},"_nodeVersion":"20.19.6","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"vite":"^5.0.0","react":"^19.2.3","eslint":"^9.17.0","zustand":"^5.0.0","prettier":"^3.6.2","typescript":"^5.3.0","@types/node":"^22.0.0","typescript-eslint":"^8.50.0","eslint-config-prettier":"^10.1.5","eslint-plugin-prettier":"^5.5.1","@typescript-eslint/parser":"^8.0.0","@typescript-eslint/eslint-plugin":"^8.0.0"},"peerDependencies":{"zustand":"^4.0.0 || ^5.0.0"},"_npmOperationalInternal":{"tmp":"tmp/zustand-getters_1.0.4_1766134597802_0.42125078799378346","host":"s3://npm-registry-packages-npm-production"}},"1.0.5":{"name":"@csark0812/zustand-getters","version":"1.0.5","keywords":["zustand","middleware","state","getters","reactive","derived-state","computed","react","state-management","javascript-getters"],"author":{"name":"Christopher Sarkissian"},"license":"MIT","_id":"@csark0812/zustand-getters@1.0.5","maintainers":[{"name":"csark0812","email":"csark0812@gmail.com"}],"homepage":"https://github.com/csark0812/zustand-getters#readme","bugs":{"url":"https://github.com/csark0812/zustand-getters/issues"},"dist":{"shasum":"2a1e0f82abba81a6998b65ef73f8723524dddfba","tarball":"https://registry.npmjs.org/@csark0812/zustand-getters/-/zustand-getters-1.0.5.tgz","fileCount":7,"integrity":"sha512-x+T/jw/V9fAisZhCRmDrRqncTHO1qY4VND6zRAkP3a1oGiS154AmbPJpidbYL97nqugaBsoLEFRM7M0Zz9g/1w==","signatures":[{"sig":"MEYCIQDDF19xaEWccWKKSt7cMUQjIFX6TivRnFP+EZFlJYmMYgIhAJm7tjy/hHzOrMbIvdYd5pWs/ToDqsO5QOKh9ARyHfUZ","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@csark0812%2fzustand-getters@1.0.5","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":23722},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/index.cjs"}},"gitHead":"ddf336824fcddde7c4ba4b25ad10f4e50934b85b","scripts":{"dev":"vite build --watch","lint":"eslint . --fix","test":"bun run build && bun run test.ts","build":"vite build && tsc --emitDeclarationOnly --declaration --outDir dist","format":"prettier . --write","example":"cd example && bun run dev","typecheck":"tsc --noEmit"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:1767fb99-c08c-45d4-8697-f832d34bf603"}},"prettier":{"semi":true,"tabWidth":2,"printWidth":100,"arrowParens":"always","singleQuote":true,"trailingComma":"all","bracketSpacing":true},"repository":{"url":"git+https://github.com/csark0812/zustand-getters.git","type":"git"},"_npmVersion":"11.9.0","description":"A Zustand middleware that makes regular JavaScript object getters reactive","directories":{},"_nodeVersion":"20.20.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"vite":"^5.0.0","react":"^19.2.3","eslint":"^9.17.0","zustand":"^5.0.0","prettier":"^3.6.2","typescript":"^5.3.0","@types/node":"^22.0.0","typescript-eslint":"^8.50.0","eslint-config-prettier":"^10.1.5","eslint-plugin-prettier":"^5.5.1","@typescript-eslint/parser":"^8.0.0","@typescript-eslint/eslint-plugin":"^8.0.0"},"peerDependencies":{"zustand":"^4.0.0 || ^5.0.0"},"_npmOperationalInternal":{"tmp":"tmp/zustand-getters_1.0.5_1770437166732_0.29333490979891286","host":"s3://npm-registry-packages-npm-production"}},"1.0.6":{"name":"@csark0812/zustand-getters","version":"1.0.6","keywords":["zustand","middleware","state","getters","reactive","derived-state","computed","react","state-management","javascript-getters"],"author":{"name":"Christopher Sarkissian"},"license":"MIT","_id":"@csark0812/zustand-getters@1.0.6","maintainers":[{"name":"csark0812","email":"csark0812@gmail.com"}],"homepage":"https://github.com/csark0812/zustand-getters#readme","bugs":{"url":"https://github.com/csark0812/zustand-getters/issues"},"dist":{"shasum":"99ef31ff17e75900d2dc6c2aaabf68831bf9420c","tarball":"https://registry.npmjs.org/@csark0812/zustand-getters/-/zustand-getters-1.0.6.tgz","fileCount":7,"integrity":"sha512-LNhnpIoeXNba+hGIrFlZ0XPcnkkh97T0H4aatTEeFeIDYL8bj+FgJJphRO+w3kHJMkjuynPc7f4DVFhaIsHAiA==","signatures":[{"sig":"MEYCIQD+FVBP9HCOAp/KM9BBpDpvzdtHRel+kwEQFkmd5rzGKAIhANBVtVxQUNzeSrnta3AmTMA9A9M+bVRQRwByd0FH1nvk","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@csark0812%2fzustand-getters@1.0.6","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":24634},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/index.cjs"}},"gitHead":"e44f6813c4263fbb1e1540c7276dde52a8311498","scripts":{"dev":"vite build --watch","lint":"eslint . --fix","test":"bun run build && bun run test.ts","build":"vite build && tsc --emitDeclarationOnly --declaration --outDir dist","format":"prettier . --write","example":"cd example && bun run dev","typecheck":"tsc --noEmit"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:1767fb99-c08c-45d4-8697-f832d34bf603"}},"prettier":{"semi":true,"tabWidth":2,"printWidth":100,"arrowParens":"always","singleQuote":true,"trailingComma":"all","bracketSpacing":true},"repository":{"url":"git+https://github.com/csark0812/zustand-getters.git","type":"git"},"_npmVersion":"11.9.0","description":"A Zustand middleware that makes regular JavaScript object getters reactive","directories":{},"_nodeVersion":"20.20.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"vite":"^5.0.0","react":"^19.2.3","eslint":"^9.17.0","zustand":"^5.0.0","prettier":"^3.6.2","typescript":"^5.3.0","@types/node":"^22.0.0","typescript-eslint":"^8.50.0","eslint-config-prettier":"^10.1.5","eslint-plugin-prettier":"^5.5.1","@typescript-eslint/parser":"^8.0.0","@typescript-eslint/eslint-plugin":"^8.0.0"},"peerDependencies":{"zustand":"^4.0.0 || ^5.0.0"},"_npmOperationalInternal":{"tmp":"tmp/zustand-getters_1.0.6_1770439293079_0.6059377077792873","host":"s3://npm-registry-packages-npm-production"}},"1.0.7":{"name":"@csark0812/zustand-getters","version":"1.0.7","keywords":["zustand","middleware","state","getters","reactive","derived-state","computed","react","state-management","javascript-getters"],"author":{"name":"Christopher Sarkissian"},"license":"MIT","_id":"@csark0812/zustand-getters@1.0.7","maintainers":[{"name":"csark0812","email":"csark0812@gmail.com"}],"homepage":"https://github.com/csark0812/zustand-getters#readme","bugs":{"url":"https://github.com/csark0812/zustand-getters/issues"},"dist":{"shasum":"89dcf6df86b766892a6d5afe915a863e2f0885c8","tarball":"https://registry.npmjs.org/@csark0812/zustand-getters/-/zustand-getters-1.0.7.tgz","fileCount":7,"integrity":"sha512-bcQinnWO4rxsjNJLFBpfyUOrHDOFlTYrDTjKmVOROg36wK7wdBneVrkSGlhfYOa2K8Py6wOothnPDgcE16wDGA==","signatures":[{"sig":"MEUCIQDqp0aPdQZyJsvssLYYviZTx6npoqDNFupYNZXPuaHHygIgWf4ZQarGMPgESmzmoBqn82QDN36PeQX0Ik4j5MKl/dw=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@csark0812%2fzustand-getters@1.0.7","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":24692},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/index.cjs"}},"gitHead":"18c2a2589d7bbd0f9ea576979830eac7a0910999","scripts":{"dev":"vite build --watch","lint":"eslint . --fix","test":"bun run build && bun run test.ts","build":"vite build && tsc --emitDeclarationOnly --declaration --outDir dist","format":"prettier . --write","example":"cd example && bun run dev","typecheck":"tsc --noEmit"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:1767fb99-c08c-45d4-8697-f832d34bf603"}},"prettier":{"semi":true,"tabWidth":2,"printWidth":100,"arrowParens":"always","singleQuote":true,"trailingComma":"all","bracketSpacing":true},"repository":{"url":"git+https://github.com/csark0812/zustand-getters.git","type":"git"},"_npmVersion":"11.9.0","description":"A Zustand middleware that makes regular JavaScript object getters reactive","directories":{},"_nodeVersion":"20.20.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"vite":"^5.0.0","react":"^19.2.3","eslint":"^9.17.0","zustand":"^5.0.0","prettier":"^3.6.2","happy-dom":"^20.5.0","typescript":"^5.3.0","@types/node":"^22.0.0","typescript-eslint":"^8.50.0","@testing-library/react":"^16.3.2","eslint-config-prettier":"^10.1.5","eslint-plugin-prettier":"^5.5.1","@typescript-eslint/parser":"^8.0.0","@typescript-eslint/eslint-plugin":"^8.0.0"},"peerDependencies":{"zustand":"^4.0.0 || ^5.0.0"},"_npmOperationalInternal":{"tmp":"tmp/zustand-getters_1.0.7_1770441202736_0.44414788726780485","host":"s3://npm-registry-packages-npm-production"}},"1.0.8":{"name":"@csark0812/zustand-getters","version":"1.0.8","keywords":["zustand","middleware","state","getters","reactive","derived-state","computed","react","state-management","javascript-getters"],"author":{"name":"Christopher Sarkissian"},"license":"MIT","_id":"@csark0812/zustand-getters@1.0.8","maintainers":[{"name":"csark0812","email":"csark0812@gmail.com"}],"homepage":"https://github.com/csark0812/zustand-getters#readme","bugs":{"url":"https://github.com/csark0812/zustand-getters/issues"},"dist":{"shasum":"e9e0b72bf8f59612c519d8c26e8230863b2b2a03","tarball":"https://registry.npmjs.org/@csark0812/zustand-getters/-/zustand-getters-1.0.8.tgz","fileCount":7,"integrity":"sha512-xbenwYc/IghUw62UcoTuMHK+aVLQgiU0lxPvmCtmOMadUS+mI4r0UHy6+g2aIinMStwb9MSt8f7wddMfh42peg==","signatures":[{"sig":"MEYCIQCPrz8gHz5UByodF9izDcvV2a7NJ/0zPdPDq3jT8QicpwIhAIRlTPHJI2ZdJFqPmh84JgV5h4uJdbPhLRJ+4KDk+zc9","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@csark0812%2fzustand-getters@1.0.8","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":24218},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/index.cjs"}},"gitHead":"9af1b61519c1c4696e65c04971ad30f59dc19181","scripts":{"dev":"vite build --watch","lint":"eslint . --fix","test":"bun run build && bun run test.ts","build":"vite build && tsc --emitDeclarationOnly --declaration --outDir dist","format":"prettier . --write","example":"cd example && bun run dev","typecheck":"tsc --noEmit"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:1767fb99-c08c-45d4-8697-f832d34bf603"}},"prettier":{"semi":true,"tabWidth":2,"printWidth":100,"arrowParens":"always","singleQuote":true,"trailingComma":"all","bracketSpacing":true},"repository":{"url":"git+https://github.com/csark0812/zustand-getters.git","type":"git"},"_npmVersion":"11.9.0","description":"A Zustand middleware that makes regular JavaScript object getters reactive","directories":{},"_nodeVersion":"20.20.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"vite":"^5.0.0","react":"^19.2.3","eslint":"^9.17.0","zustand":"^5.0.0","prettier":"^3.6.2","happy-dom":"^20.5.0","typescript":"^5.3.0","@types/node":"^22.0.0","typescript-eslint":"^8.50.0","@testing-library/react":"^16.3.2","eslint-config-prettier":"^10.1.5","eslint-plugin-prettier":"^5.5.1","@typescript-eslint/parser":"^8.0.0","@typescript-eslint/eslint-plugin":"^8.0.0"},"peerDependencies":{"zustand":"^4.0.0 || ^5.0.0"},"_npmOperationalInternal":{"tmp":"tmp/zustand-getters_1.0.8_1770442501448_0.29518031205837736","host":"s3://npm-registry-packages-npm-production"}},"1.0.9":{"name":"@csark0812/zustand-getters","version":"1.0.9","keywords":["zustand","middleware","state","getters","reactive","derived-state","computed","react","state-management","javascript-getters"],"author":{"name":"Christopher Sarkissian"},"license":"MIT","_id":"@csark0812/zustand-getters@1.0.9","maintainers":[{"name":"csark0812","email":"csark0812@gmail.com"}],"homepage":"https://github.com/csark0812/zustand-getters#readme","bugs":{"url":"https://github.com/csark0812/zustand-getters/issues"},"dist":{"shasum":"fc29beda55b977f94b412c68346fae25526c7685","tarball":"https://registry.npmjs.org/@csark0812/zustand-getters/-/zustand-getters-1.0.9.tgz","fileCount":7,"integrity":"sha512-/Khq0PwGtt/g19D7JW2CEFwj8KRV1bBQaBAxFV69PnTYGLeROdtAi7AdFs4wFRZikUZCrqG1IDoZ9xhWyjjIDg==","signatures":[{"sig":"MEUCIB0m1N5nzJSe+PFRcJqfi7HPXHgRPEnZI1jpWq8p9RhuAiEAjpQTEqPQUjNvQ/CnKQerZJq7xLZ0wdeiOBSNbxv78Cs=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@csark0812%2fzustand-getters@1.0.9","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":24551},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","require":"./dist/index.cjs"}},"gitHead":"f325c6054538d5dce85ca835c47b39b853c82115","scripts":{"dev":"vite build --watch","lint":"eslint . --fix","test":"bun run build && bun run test.ts && bun run test-persist-integration.ts && bun run test-react-components.tsx","build":"vite build && tsc --emitDeclarationOnly --declaration --outDir dist","format":"prettier . --write","example":"cd example && bun run dev","typecheck":"tsc --noEmit"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:1767fb99-c08c-45d4-8697-f832d34bf603"}},"prettier":{"semi":true,"tabWidth":2,"printWidth":100,"arrowParens":"always","singleQuote":true,"trailingComma":"all","bracketSpacing":true},"repository":{"url":"git+https://github.com/csark0812/zustand-getters.git","type":"git"},"_npmVersion":"12.0.2","description":"A Zustand middleware that makes regular JavaScript object getters reactive","directories":{},"_nodeVersion":"22.23.2","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"vite":"^5.0.0","react":"^19.2.3","eslint":"^9.17.0","zustand":"^5.0.0","prettier":"^3.6.2","happy-dom":"^20.5.0","typescript":"^5.3.0","@types/node":"^22.0.0","typescript-eslint":"^8.50.0","@testing-library/react":"^16.3.2","eslint-config-prettier":"^10.1.5","eslint-plugin-prettier":"^5.5.1","@typescript-eslint/parser":"^8.0.0","@typescript-eslint/eslint-plugin":"^8.0.0"},"peerDependencies":{"zustand":"^4.0.0 || ^5.0.0"},"_npmOperationalInternal":{"tmp":"tmp/zustand-getters_1.0.9_1787079181425_0.1024846378635893","host":"s3://npm-registry-packages-npm-production"}},"1.0.10":{"name":"@csark0812/zustand-getters","version":"1.0.10","description":"A Zustand middleware that makes regular JavaScript object getters reactive","author":{"name":"Christopher Sarkissian"},"license":"MIT","publishConfig":{"access":"public"},"type":"module","main":"./dist/index.cjs","module":"./dist/index.js","types":"./dist/index.d.ts","exports":{".":{"import":"./dist/index.js","require":"./dist/index.cjs","types":"./dist/index.d.ts"}},"scripts":{"build":"vite build && tsc --emitDeclarationOnly --declaration --outDir dist","dev":"vite build --watch","typecheck":"tsc --noEmit","test":"bun run build && bun run test.ts && bun run test-persist-integration.ts && bun run test-react-components.tsx","example":"cd example && bun run dev","lint":"eslint . --fix","format":"prettier . --write"},"peerDependencies":{"zustand":"^4.0.0 || ^5.0.0"},"devDependencies":{"@testing-library/react":"^16.3.2","@types/node":"^22.0.0","@typescript-eslint/eslint-plugin":"^8.0.0","@typescript-eslint/parser":"^8.0.0","eslint":"^9.17.0","eslint-config-prettier":"^10.1.5","eslint-plugin-prettier":"^5.5.1","happy-dom":"^20.5.0","prettier":"^3.6.2","react":"^19.2.3","typescript":"^5.3.0","typescript-eslint":"^8.50.0","vite":"^5.0.0","zustand":"^5.0.0"},"keywords":["zustand","middleware","state","getters","reactive","derived-state","computed","react","state-management","javascript-getters"],"repository":{"type":"git","url":"git+https://github.com/csark0812/zustand-getters.git"},"bugs":{"url":"https://github.com/csark0812/zustand-getters/issues"},"homepage":"https://github.com/csark0812/zustand-getters#readme","prettier":{"semi":true,"singleQuote":true,"trailingComma":"all","printWidth":100,"tabWidth":2,"bracketSpacing":true,"arrowParens":"always"},"gitHead":"c94a5c89584ada4c32defcab6a16caa19ad07d42","_id":"@csark0812/zustand-getters@1.0.10","_nodeVersion":"22.23.2","_npmVersion":"12.0.2","dist":{"integrity":"sha512-pm0qWU+Zt//M9rco01X9dKDVSNeadkJ4ia+nSDMqjVdb8DpasxeiIBUImZfvzbgrlrDsW5uX/O4BVHK+LXpXNw==","shasum":"5db3778c7de7821c6cd26a45b1fcffea1bfc7549","tarball":"https://registry.npmjs.org/@csark0812/zustand-getters/-/zustand-getters-1.0.10.tgz","fileCount":7,"unpackedSize":24824,"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@csark0812%2fzustand-getters@1.0.10","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQC63rOQEJBJdSuFyUuzX5nTch6iKjvtzbjyzUHmxyVsYAIgc91Q0SjpsFGLACg1+/Ak9H2j5IfZwWTHAji2muMFuSE="}]},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:1767fb99-c08c-45d4-8697-f832d34bf603"}},"directories":{},"maintainers":[{"name":"csark0812","email":"csark0812@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/zustand-getters_1.0.10_1788242034233_0.640399954821804"},"_hasShrinkwrap":false}},"time":{"created":"2025-12-19T08:45:29.087Z","modified":"2026-09-01T05:53:54.920Z","1.0.0":"2025-12-19T08:45:29.308Z","1.0.3":"2025-12-19T08:55:22.439Z","1.0.4":"2025-12-19T08:56:37.941Z","1.0.5":"2026-02-07T04:06:06.883Z","1.0.6":"2026-02-07T04:41:33.234Z","1.0.7":"2026-02-07T05:13:22.899Z","1.0.8":"2026-02-07T05:35:01.614Z","1.0.9":"2026-08-18T18:53:01.561Z","1.0.10":"2026-09-01T05:53:54.625Z"},"bugs":{"url":"https://github.com/csark0812/zustand-getters/issues"},"author":{"name":"Christopher Sarkissian"},"license":"MIT","homepage":"https://github.com/csark0812/zustand-getters#readme","keywords":["zustand","middleware","state","getters","reactive","derived-state","computed","react","state-management","javascript-getters"],"repository":{"type":"git","url":"git+https://github.com/csark0812/zustand-getters.git"},"description":"A Zustand middleware that makes regular JavaScript object getters reactive","maintainers":[{"name":"csark0812","email":"csark0812@gmail.com"}],"readme":"# @csark0812/zustand-getters\n\n[![NPM](https://img.shields.io/npm/v/@csark0812/zustand-getters.svg)](https://www.npmjs.com/package/@csark0812/zustand-getters)\n[![Bundle Size](https://img.shields.io/bundlephobia/minzip/@csark0812/zustand-getters)](https://bundlephobia.com/package/@csark0812/zustand-getters)\n[![License](https://img.shields.io/npm/l/@csark0812/zustand-getters.svg)](https://github.com/csark0812/zustand-getters/blob/main/LICENSE)\n\nA lightweight, TypeScript-friendly middleware for [Zustand](https://github.com/pmndrs/zustand) that makes regular JavaScript object getters reactive. Define derived values with `get propertyName()` and they automatically trigger React updates when accessed.\n\n> **Why Vite in root?** Vite is used as the build tool to compile the TypeScript middleware into distributable JavaScript (ESM + CJS) with type definitions. It's not a web server here—just a fast, modern bundler for library builds.\n\n## Why?\n\nWriting reactive derived state in Zustand typically requires manual selectors or separate computed libraries. This middleware lets you use native JavaScript getters and makes them automatically reactive:\n\n- ✨ Use regular JavaScript `get propertyName()` syntax\n- 🔄 Automatic React updates when getter dependencies change\n- ⚡ Plain values remain fast (not wrapped in proxies)\n- 🎯 Works recursively for nested objects\n- 📦 Tiny bundle size with zero dependencies (beyond Zustand)\n- 🔒 Full TypeScript support\n\n## Install\n\n```bash\nbun add @csark0812/zustand-getters\n# or\nnpm install @csark0812/zustand-getters\n# or\npnpm add @csark0812/zustand-getters\n# or\nyarn add @csark0812/zustand-getters\n```\n\n## Quick Start\n\n```typescript\nimport { create } from 'zustand'\nimport { getters } from '@csark0812/zustand-getters'\n\ninterface CounterState {\n  count: number\n  double: number\n  increment: () => void\n}\n\nconst useStore = create<CounterState>()(\n  getters((set) => ({\n    count: 5,\n    // Define a reactive getter - it automatically updates React when accessed!\n    get double() {\n      return this.count * 2\n    },\n    increment: () => set((state) => ({\n      ...state,\n      count: state.count + 1\n    })),\n  }))\n)\n\n// In React components\nfunction Counter() {\n  // Selecting the getter automatically makes this component reactive\n  const double = useStore((state) => state.double)\n  const count = useStore((state) => state.count)\n  const increment = useStore((state) => state.increment)\n\n  return (\n    <div>\n      <div>Count: {count}</div>\n      <div>Double: {double}</div>\n      <button onClick={increment}>Increment</button>\n    </div>\n  )\n}\n\n// When count changes, components selecting 'double' automatically re-render!\n```\n\n## Features\n\n### 🔄 Reactive JavaScript Getters\n\nThe middleware automatically wraps JavaScript object getters (defined with `get propertyName()`) to trigger React updates when accessed:\n\n```typescript\ninterface StoreState {\n  count: number\n  step: number\n  double: number\n  triple: number\n  countPlusStep: number\n  increment: () => void\n}\n\nconst useStore = create<StoreState>()(\n  getters((set) => ({\n    count: 0,\n    step: 1,\n    // These getters are now reactive!\n    get double() {\n      return this.count * 2;\n    },\n    get triple() {\n      return this.count * 3;\n    },\n    get countPlusStep() {\n      return this.count + this.step;\n    },\n    increment: () => set((state) => ({\n      ...state,\n      count: state.count + state.step,\n    })),\n  }))\n);\n\n// In your component, selecting a getter makes it reactive\nfunction MyComponent() {\n  const double = useStore((state) => state.double);\n  // Re-renders automatically when count changes!\n  return <div>{double}</div>;\n}\n```\n\n### 🎯 Nested Object Support\n\nWorks recursively with nested objects:\n\n```typescript\ninterface UserState {\n  firstName: string;\n  lastName: string;\n  fullName: string;\n  initials: string;\n  setFirstName: (name: string) => void;\n}\n\nconst useStore = create<UserState>()(\n  getters((set) => ({\n    firstName: 'Chris',\n    lastName: 'Sarkissian',\n    // Reactive getters combining fields\n    get fullName() {\n      return `${this.firstName} ${this.lastName}`;\n    },\n    get initials() {\n      return `${this.firstName[0]}${this.lastName[0]}`;\n    },\n    setFirstName: (name: string) =>\n      set((state) => ({\n        ...state,\n        firstName: name,\n      })),\n    setLastName: (name: string) =>\n      set((state) => ({\n        ...state,\n        lastName: name,\n      })),\n  })),\n);\n```\n\n### ⚡ Performance Optimized\n\nOnly JavaScript getters are wrapped—plain values remain fast and untouched:\n\n```typescript\nconst useStore = create(\n  getters((set) => ({\n    count: 5, // Plain value - not wrapped, very fast\n    get double() {\n      // Getter - wrapped for reactivity\n      return this.count * 2;\n    },\n  })),\n);\n```\n\n## API Reference\n\n### `getters(stateCreator)`\n\nThe main middleware function that wraps all JavaScript object getters to make them reactive.\n\n#### Parameters\n\n- `stateCreator`: Your Zustand state creator function\n\n#### Returns\n\nA wrapped state creator with reactive getters.\n\n#### How It Works\n\n1. Detects all JavaScript getters in your state (properties defined with `get propertyName()`)\n2. Wraps each getter to call `set(state => state)` when accessed, triggering React updates\n3. Leaves plain values untouched for optimal performance\n4. Works recursively for nested objects\n\n### `createGetters()`\n\nAlternative API for creating the middleware.\n\n```typescript\nconst withGetters = createGetters<Store>();\n\nconst useStore = create<Store>()(\n  withGetters((set) => ({\n    // your state with getters\n  })),\n);\n```\n\n## Usage with Other Middleware\n\nYou can combine `@csark0812/zustand-getters` with other Zustand middleware:\n\n```typescript\nimport { create } from 'zustand';\nimport { devtools, persist } from 'zustand/middleware';\nimport { getters } from '@csark0812/zustand-getters';\n\nconst useStore = create(\n  devtools(\n    persist(\n      getters((set) => ({\n        count: 0,\n        get double() {\n          return this.count * 2;\n        },\n        increment: () =>\n          set((state) => ({\n            ...state,\n            count: state.count + 1,\n          })),\n      })),\n      { name: 'counter-storage' },\n    ),\n  ),\n);\n```\n\n### With Immer\n\nWhen using with `immer`, place `getters` **outside** (wrapping) `immer` for proper type inference:\n\n```typescript\nimport { create } from 'zustand';\nimport { immer } from 'zustand/middleware/immer';\nimport { getters } from '@csark0812/zustand-getters';\n\ninterface TodoState {\n  todos: { id: string; text: string; done: boolean }[];\n  activeCount: number;\n  addTodo: (text: string) => void;\n  toggleTodo: (id: string) => void;\n}\n\n// ✅ Correct - getters wraps immer\nconst useTodoStore = create<TodoState>()(\n  getters(\n    immer((set) => ({\n      todos: [],\n      get activeCount() {\n        return this.todos.filter((t) => !t.done).length;\n      },\n      addTodo: (text) =>\n        set((state) => {\n          state.todos.push({ id: Date.now().toString(), text, done: false });\n        }), // void return is OK with immer!\n      toggleTodo: (id) =>\n        set((state) => {\n          const todo = state.todos.find((t) => t.id === id);\n          if (todo) todo.done = !todo.done;\n        }),\n    })),\n  ),\n);\n```\n\nThis ordering ensures that:\n\n- TypeScript properly infers that `set` accepts void-returning functions (immer's signature)\n- Getters work correctly with immer's draft state\n- Full type safety is preserved\n\n## TypeScript Support\n\nFull TypeScript support with automatic type inference:\n\n```typescript\ninterface Store {\n  count: number;\n  readonly double: number; // Getter property\n  increment: () => void;\n}\n\nconst useStore = create<Store>(\n  getters((set) => ({\n    count: 0,\n    get double() {\n      return this.count * 2;\n    },\n    increment: () => set((state) => ({\n      ...state,\n      count: state.count + 1,\n    })),\n  }))\n);\n\n// Type-safe access in components\nfunction MyComponent() {\n  const double = useStore((state) => state.double); // number\n  const count = useStore((state) => state.count); // number\n  return <div>{double}</div>;\n}\n```\n\n## Examples\n\nCheck out the `example/` directory for a full React application demonstrating:\n\n- Counter with reactive derived getters (double, triple, countPlusStep)\n- User store with fullName and initials getters\n- Shopping cart with automatic subtotal, tax, and total calculations\n- Nested object support and performance optimization\n\nTo run the example:\n\n```bash\n# Install dependencies\nbun install\ncd example && bun install\n\n# Run the example\nbun run dev\n```\n\n## How It Works\n\nThe middleware wraps your state creator and:\n\n1. Recursively traverses your state object\n2. Detects JavaScript getters (properties defined with `get propertyName()`)\n3. Wraps each getter to trigger `set(state => state)` when accessed\n4. Leaves plain values and methods untouched for optimal performance\n5. React components selecting wrapped getters automatically re-render when the underlying data changes\n\n**Key Insight**: When a getter is accessed, it first triggers a state update via `set(state => state)`, then returns the computed value. This ensures React components using that getter are notified to re-render, but the getter still returns the current value immediately.\n\n## Development & Debugging\n\nSee [DEBUG.md](./DEBUG.md) for a comprehensive debugging guide including:\n\n- Development workflow\n- Console logging techniques\n- Browser debugging\n- Common issues and solutions\n\nQuick test:\n\n```bash\nbun run test\n```\n\n## Examples\n\nThe `example/` directory contains comprehensive demonstrations of the getters middleware at different complexity levels:\n\n### 🎮 Interactive Demo\n\n```bash\ncd example\nbun install\nbun run dev\n```\n\n### 📚 Example Categories\n\n**Basic Examples** (without immer)\n\n- Simple counter with computed values (`double`, `triple`)\n- User info with string manipulation (`fullName`, `initials`)\n\n**Intermediate Examples**\n\n- Shopping cart with chained getters (subtotal → discount → tax → total)\n- Todo list with immer showing filtered views and stats\n\n**Advanced Examples**\n\n- Analytics dashboard with complex statistical calculations\n- Form validation with cross-field validation and error aggregation\n\n**Special Demos**\n\n- Readonly demo proving getters cannot be set\n\nEach example includes:\n\n- 🔄 Render counters to demonstrate selective rerendering\n- 📊 Isolated components showing getter reactivity\n- 💡 Code snippets explaining the implementation\n- ✨ Both immer and non-immer approaches\n\nSee [`example/EXAMPLES.md`](./example/EXAMPLES.md) for detailed documentation.\n\n## Troubleshooting\n\n### Getter not updating my component\n\n**Problem:** Component doesn't re-render when getter dependencies change.\n\n**Solution:** Make sure you're selecting the getter in your component:\n\n```typescript\n// ✅ Correct - selects the getter\nconst double = useStore((state) => state.double);\n\n// ❌ Wrong - doesn't trigger updates\nconst store = useStore();\nconst double = store.double; // Won't update!\n```\n\n### TypeScript errors with immer\n\n**Problem:** TypeScript complains about `set` returning void.\n\n**Solution:** Place `getters` **outside** `immer`:\n\n```typescript\n// ✅ Correct\ncreate<State>()(\n  getters(\n    immer((set) => ({\n      /* ... */\n    })),\n  ),\n);\n\n// ❌ Wrong\ncreate<State>()(\n  immer(\n    getters((set) => ({\n      /* ... */\n    })),\n  ),\n);\n```\n\n### Infinite loop or maximum call stack error\n\n**Problem:** Getter creates infinite recursion.\n\n**Solution:** Avoid circular dependencies in getters:\n\n```typescript\n// ❌ Bad - circular dependency\nget a() { return this.b + 1; }\nget b() { return this.a + 1; }\n\n// ✅ Good - no circular dependency\nget double() { return this.count * 2; }\nget quadruple() { return this.double * 2; }\n```\n\n### Performance issues with complex getters\n\n**Problem:** Getter computation is slow.\n\n**Solution:** Optimize the computation itself or consider memoizing expensive operations outside the getter:\n\n```typescript\n// Optimize the computation\nget filteredItems() {\n  // Use efficient algorithms\n  return this.items.filter(/* optimized filter */);\n}\n```\n\n### Getter returns wrong value after state update\n\n**Problem:** State updated but getter shows old value.\n\n**Solution:** Use immutable updates (follow Zustand best practices):\n\n```typescript\n// ✅ Correct - immutable update\nincrement: () =>\n  set((state) => ({\n    ...state,\n    count: state.count + 1,\n  }));\n\n// ❌ Wrong - mutation\nincrement: () => {\n  this.count++; // Don't mutate!\n  set((state) => state);\n};\n```\n\n### Still having issues?\n\n1. Check the [examples directory](./example) for working code\n2. Search [existing issues](https://github.com/csark0812/zustand-getters/issues)\n3. Open a [new issue](https://github.com/csark0812/zustand-getters/issues/new) with a minimal reproduction\n\n## Comparison with zustand-computed\n\nWhile [zustand-computed](https://github.com/chrisvander/zustand-computed) computes derived state eagerly on every state change, `@csark0812/zustand-getters` makes JavaScript getters reactive and lazy—they only trigger updates when accessed by a React component. This provides:\n\n- **Lazy evaluation**: Getters only compute when needed\n- **Native syntax**: Use standard `get propertyName()` syntax\n- **Performance**: Plain values remain fast, only getters are wrapped\n- **Simplicity**: No separate computed config needed\n\n## Related work\n\n- [Zustand Expo DevTools](https://github.com/csark0812/zustand-expo-devtools) brings state inspection and time-travel debugging to Expo apps.\n- [Christopher's profile](https://github.com/csark0812) connects the broader mobile and developer-tooling work.\n\n## Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request at [https://github.com/csark0812/zustand-getters](https://github.com/csark0812/zustand-getters).\n\n## License\n\nMIT © Christopher Sarkissian\n\n## Credits\n\nInspired by [zustand-computed](https://github.com/chrisvander/zustand-computed) by @chrisvander.\n","readmeFilename":"README.md"}