{"_id":"@djunger02/redux-set-state","_rev":"5-044ff11e28b9420ba6e63d4a617a1eff","name":"@djunger02/redux-set-state","dist-tags":{"latest":"1.0.5"},"versions":{"1.0.0":{"name":"@djunger02/redux-set-state","version":"1.0.0","description":"A generic reducer that might be all you need","main":"lib/index.js","scripts":{"lint":"eslint src test","test":"echo \"Error: no test specified\" && exit 1","build":"npm run build:commonjs && npm run build:umd && npm run build:umd:min && npm run build:es","build:commonjs":"cross-env BABEL_ENV=commonjs babel src --out-dir lib","build:es":"cross-env BABEL_ENV=es babel src --out-dir es","build:umd":"cross-env BABEL_ENV=commonjs NODE_ENV=development webpack","build:umd:min":"cross-env BABEL_ENV=commonjs NODE_ENV=production webpack"},"module":"es/index.js","author":{"name":"Dan Junger"},"license":"MIT","devDependencies":{"@babel/cli":"^7.0.0","@babel/core":"^7.0.0","@babel/preset-env":"^7.0.0","babel-loader":"^8.0.2","cross-env":"^5.2.0","updeep":"^1.0.0","webpack":"^4.18.0","webpack-cli":"^3.1.0"},"repository":{"type":"git","url":"git+https://github.com/danjunger/redux-set-state.git"},"gitHead":"12eab7dff6d9ff70938739986147add65c95973b","bugs":{"url":"https://github.com/danjunger/redux-set-state/issues"},"homepage":"https://github.com/danjunger/redux-set-state#readme","_id":"@djunger02/redux-set-state@1.0.0","_npmVersion":"6.1.0","_nodeVersion":"10.7.0","_npmUser":{"name":"djunger02","email":"junger.da@gmail.com"},"dist":{"integrity":"sha512-DdtnB9HCh+KoQlxjFXyLCw+ln7JPWvhVFUOPkGwE/eJMYTZUAVF0aZZNHtxATyel995BECLl5A59gl/aMKhcwg==","shasum":"0b33f22d11f3565dbb935e9da1ee82b5c54e1c2d","tarball":"https://registry.npmjs.org/@djunger02/redux-set-state/-/redux-set-state-1.0.0.tgz","fileCount":6,"unpackedSize":122774,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbmFnBCRA9TVsSAnZWagAAHakP/R4fAsAsJ4pRuVXOmlDE\n6FgjzucBzq1yuxuG3q5LYnr3mROCGUgmq8DxBQrj5feGYX17mlfJM0GAC+9m\nN4OMFXuWwDrlRnNCJ25f7FfM4eRaeBtTjR8iyVGqN07HlOZBuZ/5V77CmxLM\nTqQETb1ZYKNBumz+L4HZw7mIEqzcfDHShn0Pq7Cx7yEL2VXx2obNuJ6WCpxd\n6mRsxUHcaUWRAm7GwJuw0fJdgpM++PbbUyvkoGWzDVUbTGKZRwIgrpQTnwb+\nFaJT9xVo3TKVN6jRdIuOpd7CMrybyOTXw+87FK3ILWmHmnqvlweHfvoCGsBx\ngDargTYr5PlH3D03E6I0MVjMFAJCQwuSk352mNviknpgQkzPG8wgkco8uHix\nn11tDkrWTgQd3AXLYXdMf5OUSEfLQsO5s1eT/kDMJjqJK+WMt/5gLdIChWI4\nIE6bv9UHmw2tQjvRj9ujGI0ID8o/4xnEhO3EBHf9U1Hc1ns4MFzV8RyK+4Q/\nmx0fKOwJEu8F22L/9X/YePcKnyAT2bgO4jz0weKH0aQVLBMN5VR3h+jv0oMe\neK592cNuPobs4LvQApbsXspUBYYhKD7BdMiUiL1r3b+HytYnAGsOClTEO9pJ\nHOQ4/wvsBz60ve357iISodifraM8yAjkDIjvqeqFj7uyvAlHgF0mqMubAEEn\nMsuZ\r\n=FOeK\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIGA1FhKhegVzd6qnFGf/rUyk0w7U5/XnV3Yl/Ivpd6svAiByy1doQw7+Nvn25gX+tm3qz03dNQavv3nIAdYjkO5KCg=="}]},"maintainers":[{"name":"djunger02","email":"junger.da@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/redux-set-state_1.0.0_1536711104744_0.3597557205295536"},"_hasShrinkwrap":false},"1.0.1":{"name":"@djunger02/redux-set-state","version":"1.0.1","description":"A generic reducer that might be all you need","main":"lib/index.js","scripts":{"lint":"eslint src test","test":"echo \"Error: no test specified\" && exit 1","build":"npm run build:commonjs && npm run build:umd && npm run build:umd:min && npm run build:es","build:commonjs":"cross-env BABEL_ENV=commonjs babel src --out-dir lib","build:es":"cross-env BABEL_ENV=es babel src --out-dir es","build:umd":"cross-env BABEL_ENV=commonjs NODE_ENV=development webpack","build:umd:min":"cross-env BABEL_ENV=commonjs NODE_ENV=production webpack"},"module":"es/index.js","author":{"name":"Dan Junger"},"license":"MIT","dependencies":{"updeep":"^1.0.0"},"devDependencies":{"@babel/cli":"^7.0.0","@babel/core":"^7.0.0","@babel/preset-env":"^7.0.0","babel-loader":"^8.0.2","cross-env":"^5.2.0","webpack":"^4.18.0","webpack-cli":"^3.1.0"},"repository":{"type":"git","url":"git+https://github.com/danjunger/redux-set-state.git"},"gitHead":"9d75ccc0bbc8990e237c7b0ecc0fa1b3733898a8","bugs":{"url":"https://github.com/danjunger/redux-set-state/issues"},"homepage":"https://github.com/danjunger/redux-set-state#readme","_id":"@djunger02/redux-set-state@1.0.1","_npmVersion":"6.1.0","_nodeVersion":"10.7.0","_npmUser":{"name":"djunger02","email":"junger.da@gmail.com"},"dist":{"integrity":"sha512-Qml0fWBlUBMU8DeXxQPTpD4mfnuQLDzqaEzoEm8RVMJyCRs4sBNvFAcnzL21b9awlT6hjGrk+a0ZpPUcH6Yltw==","shasum":"c0772b0fc86f8abcad9c121b97b4add5a6ca7d91","tarball":"https://registry.npmjs.org/@djunger02/redux-set-state/-/redux-set-state-1.0.1.tgz","fileCount":6,"unpackedSize":122798,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbmFsECRA9TVsSAnZWagAAcOQP/3JR/eurkk5jgE9kmmPs\n2XBbKNkxrpUOn6nEF3pK+R17rmZGICaXtvUwipo0zB6PI99wcorMMnueFZLv\nFiVNXUA1CFOUyYZlJFWsGg4X0GcVCxHI79RCPY9qP577gRBYxiuMXGWOgoNP\nTXTPvOX9ppHBxlhWW92wN3J/YX+rsgRlnx1XGbBADNhdV0AnT4rDrc8whqTs\n/CBngtYMt3vcGak7vVJ9vMwqxXVVhVPqvbTBab9uUfZBUlcBdLqIm/rnQnyE\nk2Tqomj8ShGSlEJCpgKeP0Q1F7HcaQ0okebjNqllRoXv15e9cKn8rTAISOv0\nFze0m5V2U6N6wBkJJlVHvQM43PiP+9aiTMxW9ijOW5OqVlFZytD3h2qXpwEx\n+FehGgzjYp9WVKxbzk+uGoYnsNCJm6GdnmiOm/0rw9dGeHXbzEfQkkskGB+z\najyMcBTXgJ5TZcTvE3jnQ76XtHTMW63G+qF/ggrz69x3i3BZzTMXMKr3phM0\n2J7a3vOcRZ4qq55JwpyzUTrOhUYPlGlLu8JYma4BFOWsaVmBeK1moBoZpRBI\nmA+4VYaBwXfVd3haYMPAg9TGRLHi2WQCF0qhRXSOWp4Z60qIABYfvwxhaWlG\nNIngSFfbszqTMzVzUsugG4+mABiCYy5CqDzfC6DlIb3IMMkfRu65rjfowOp7\nqiQr\r\n=SDox\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIBgkcKbf18bNzMZ5RzvJOqcBA4naiv/SVCLuLxTbsmwVAiBSGuZ5vU9ejJ+XHquwbW6d5PzO/RA28Z6TLG2WNLP2cw=="}]},"maintainers":[{"name":"djunger02","email":"junger.da@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/redux-set-state_1.0.1_1536711427992_0.07254654985027642"},"_hasShrinkwrap":false},"1.0.2":{"name":"@djunger02/redux-set-state","version":"1.0.2","description":"A generic reducer that might be all you need","main":"lib/index.js","scripts":{"lint":"eslint src test","test":"jest","build":"npm run build:commonjs && npm run build:umd && npm run build:umd:min && npm run build:es","build:commonjs":"cross-env BABEL_ENV=commonjs babel src --out-dir lib","build:es":"cross-env BABEL_ENV=es babel src --out-dir es","build:umd":"cross-env BABEL_ENV=commonjs NODE_ENV=development webpack","build:umd:min":"cross-env BABEL_ENV=commonjs NODE_ENV=production webpack"},"module":"es/index.js","author":{"name":"Dan Junger"},"license":"MIT","dependencies":{"updeep":"^1.0.0"},"devDependencies":{"@babel/cli":"^7.0.0","@babel/core":"^7.0.1","@babel/preset-env":"^7.0.0","babel-core":"^7.0.0-0","babel-jest":"^23.6.0","babel-loader":"^8.0.2","cross-env":"^5.2.0","eslint":"^5.5.0","eslint-config-airbnb":"^17.1.0","eslint-plugin-import":"^2.14.0","eslint-plugin-jsx-a11y":"^6.1.1","eslint-plugin-react":"^7.11.1","jest":"^23.6.0","webpack":"^4.18.0","webpack-cli":"^3.1.0"},"repository":{"type":"git","url":"git+https://github.com/danjunger/redux-set-state.git"},"gitHead":"7c1657732df70eaadb726c9abfc52cb2bccb083a","bugs":{"url":"https://github.com/danjunger/redux-set-state/issues"},"homepage":"https://github.com/danjunger/redux-set-state#readme","_id":"@djunger02/redux-set-state@1.0.2","_npmVersion":"6.1.0","_nodeVersion":"10.7.0","_npmUser":{"name":"djunger02","email":"junger.da@gmail.com"},"dist":{"integrity":"sha512-iaqcvdo+hHSX0beGK9giBnnVkBHiVpk75HHp7tN9SkBgdJurjtvJgucU14SVXorVnLPOApYkfnWpL9oMW/lsww==","shasum":"a53df5f2fe66c1d779392872eeabbe25c5678c71","tarball":"https://registry.npmjs.org/@djunger02/redux-set-state/-/redux-set-state-1.0.2.tgz","fileCount":10,"unpackedSize":203851,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbmWXACRA9TVsSAnZWagAA7OEP/36/Me8zPJWetZIba5aS\n7XrQlhoXP1MElIhDrlyRUL6RwyvMB5rvYrIBZnlC3lsxRPCa41a/U7tGGO74\n05jP+b5nmNf0hk7CyqdJ7iP4OmqX6w+gYg0fxlgUNPX+O+cGTYstbsjCY5jr\nxfZjWDFThK4NFOgaKU4RAYzqqofdP85M5WluKu3tA0aZecSeR+mpIzb0z4Wr\nzg24sVa3bI0YKYvzJitwB4Bly6iYqI/yzHTIFqyiviO3xkCJAkh+beiyZ7ef\nhF/sgWk4rSX/3sr082wtzBpLIlXFMcOatTndewkuaBv5xwN2CjEDkPX28Jwf\nFeWA4cHKlSe18Pvz9bam6DsII8ftLago4VpjLXLzBoKBg6iiqftGxuRPcOuV\nZEko9As/U4u6WHf3XEeUuncEEdiMpFkm74v1g0Ljx3sTfb8fg33+zPiG2XEk\n8cJxQOs/12OfP8fF9n04xJm1eK6FuYnvPuWupdeb38mT3Ec87SuvkP61RR2b\nBMJKvKCMk64pVJZJioHbcumeh9gOLOhnvIkL7JodDz+TEZOPH0Y8Qs4c+q/X\nveG2qeyxiNYOWbHk1+qRQthon+6OM3Y/6/YZDOWnzmMQbq0NzShkgRMxzrz7\ncJJvI+r/EQNF4AwO3xwr7SdqPD+wT72xWAfh29HHZG1AvWfhYvQL1l6QQjEt\nhjS9\r\n=3zNl\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQC0Ww9Ns5dq5nbvGnjx37k4xyWVl0rnCotCnpqa5uAgPQIgAsEUMA5JarxmKjTAMHfUp1RiKKopznZCWyBKdXWnVEM="}]},"maintainers":[{"name":"djunger02","email":"junger.da@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/redux-set-state_1.0.2_1536779711405_0.008641485322617992"},"_hasShrinkwrap":false},"1.0.3":{"name":"@djunger02/redux-set-state","version":"1.0.3","description":"A generic reducer that might be all you need","main":"lib/index.js","scripts":{"lint":"eslint src test","test":"jest","build":"npm run build:commonjs && npm run build:umd && npm run build:umd:min && npm run build:es","build:commonjs":"cross-env BABEL_ENV=commonjs babel src --out-dir lib","build:es":"cross-env BABEL_ENV=es babel src --out-dir es","build:umd":"cross-env BABEL_ENV=commonjs NODE_ENV=development webpack","build:umd:min":"cross-env BABEL_ENV=commonjs NODE_ENV=production webpack"},"module":"es/index.js","author":{"name":"Dan Junger"},"license":"MIT","dependencies":{"updeep":"^1.0.0"},"devDependencies":{"@babel/cli":"^7.0.0","@babel/core":"^7.0.1","@babel/preset-env":"^7.0.0","babel-core":"^7.0.0-0","babel-jest":"^23.6.0","babel-loader":"^8.0.2","cross-env":"^5.2.0","eslint":"^5.5.0","eslint-config-airbnb":"^17.1.0","eslint-plugin-import":"^2.14.0","eslint-plugin-jsx-a11y":"^6.1.1","eslint-plugin-react":"^7.11.1","jest":"^23.6.0","webpack":"^4.18.0","webpack-cli":"^3.1.0"},"repository":{"type":"git","url":"git+https://github.com/danjunger/redux-set-state.git"},"gitHead":"a4a5310fe944bac85dd935ef99a5ea1d458549fa","bugs":{"url":"https://github.com/danjunger/redux-set-state/issues"},"homepage":"https://github.com/danjunger/redux-set-state#readme","_id":"@djunger02/redux-set-state@1.0.3","_npmVersion":"6.1.0","_nodeVersion":"10.7.0","_npmUser":{"name":"djunger02","email":"junger.da@gmail.com"},"dist":{"integrity":"sha512-Gezrzyl13t6+U60FH0ZSr+H0l0nhZ3rNpua7jz6enlv6UItLKgN8PYr9xThEf0gEiTypludcmTduB9EphZTM4g==","shasum":"c232bf9f866f8d785948d489158316deaa4f0f50","tarball":"https://registry.npmjs.org/@djunger02/redux-set-state/-/redux-set-state-1.0.3.tgz","fileCount":10,"unpackedSize":204041,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbmWanCRA9TVsSAnZWagAAkTQQAJdOm+GQTlMr52eKINvl\ngQnMmDqruFdrbBnvAC0ccMSEh0okw48ouM8XX4deY/l3l69ilPUNClAbr2Rg\nkx9S1AxB6wSRcekFodclBVuL7Zs+wk7gKo6vuQTRNNYhSn7WfJ9y7ks0gl4n\nNXAm7czUuunb1X4j6dXGkhR+YadKu89U0RchKJUyLU6uzZqRDxPx8IUjJoGv\nVqa2km0ki/qwFfnXKesNO1pcyvCG8zeQrXcmHYE7Q4aOMrxXBwzfwWLG29dV\nHii+Ew5bHOExYw+OcRIwU927o6dCQV1TN8cNKcg64def9eXzdRHUZ1+idF+g\nw5jQ1mI75ft6zyePmDW87wuWdxiMhZHA5XZwM8R6HmTdilcyvzq71cBEcnGx\nggE01TJqqQ8hNcnxgQrw/5k11uGBzVJdLuqj/yref1LDxJ0XgeMujtMR7g3A\nxKRTdVNoEVtkrUFM/DM6t812zfSOPoKPXXT2mWE44kUSgsJGLzZDDwYRieLh\nuRosKUiO33qwKp082a9M+OscMsgJKvc7HAmEdzysb+cs8qyzTsy0I4FEzIdW\nOdoG/gEkyaEmn/z8EZ/5tjydO5ggiVakICdPnAQu7FnG5LoKU1tn1KTHgOPS\nYCViN88bknXzKV7vxWJxnN7EWjFT2LDlJKvJfhWASRLObvx4hd8uMTz2Tv8y\nExVM\r\n=lwKd\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDGq5Ljf+3tRAl8TEn6Alukqg6LfEUMkM9TgO3i3pmhHAIhALYT48jHiX4485IPNWOsDKLylOyhsAfoEQi/xJGnBqLO"}]},"maintainers":[{"name":"djunger02","email":"junger.da@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/redux-set-state_1.0.3_1536779942710_0.8029747741695967"},"_hasShrinkwrap":false},"1.0.5":{"name":"@djunger02/redux-set-state","version":"1.0.5","description":"A generic reducer that might be all you need","main":"lib/index.js","scripts":{"lint":"eslint src test","test":"jest","build":"npm run build:commonjs && npm run build:umd && npm run build:umd:min && npm run build:es","build:commonjs":"cross-env BABEL_ENV=commonjs babel src --out-dir lib","build:es":"cross-env BABEL_ENV=es babel src --out-dir es","build:umd":"cross-env BABEL_ENV=commonjs NODE_ENV=development webpack","build:umd:min":"cross-env BABEL_ENV=commonjs NODE_ENV=production webpack"},"module":"es/index.js","author":{"name":"Dan Junger"},"license":"MIT","dependencies":{"updeep":"^1.0.0"},"devDependencies":{"@babel/cli":"^7.0.0","@babel/core":"^7.0.1","@babel/preset-env":"^7.0.0","babel-core":"^7.0.0-0","babel-jest":"^23.6.0","babel-loader":"^8.0.2","cross-env":"^5.2.0","eslint":"^5.5.0","eslint-config-airbnb":"^17.1.0","eslint-plugin-import":"^2.14.0","eslint-plugin-jsx-a11y":"^6.1.1","eslint-plugin-react":"^7.11.1","jest":"^23.6.0","webpack":"^4.18.0","webpack-cli":"^3.1.0"},"repository":{"type":"git","url":"git+https://github.com/danjunger/redux-set-state.git"},"gitHead":"2a523a9d41f84088d88e638222e27ebde6313a70","bugs":{"url":"https://github.com/danjunger/redux-set-state/issues"},"homepage":"https://github.com/danjunger/redux-set-state#readme","_id":"@djunger02/redux-set-state@1.0.5","_npmVersion":"6.1.0","_nodeVersion":"10.7.0","_npmUser":{"name":"djunger02","email":"junger.da@gmail.com"},"dist":{"integrity":"sha512-+VK85Ni3Li2MVEs99lk7ZKmX4tJ8FA+1dsbcb8Y/2zrAXEpos+bHxuMJ+yrWzaa+1p8VLFsb21++7rCtYC9xfA==","shasum":"43df7f68dca93cd321ffd540b79c2f75b811ad17","tarball":"https://registry.npmjs.org/@djunger02/redux-set-state/-/redux-set-state-1.0.5.tgz","fileCount":12,"unpackedSize":204744,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcD1skCRA9TVsSAnZWagAARxwP/jZNDueXYNpOzPHstSRm\nT7a8JD5xgxBOt6DvFeCBMgM9bFBF21d7nUC7MxrXsZrpEDoucZB66vMunMG2\n/t9FUAmFTDhNKcu+lyG90DY/11H4T9WKTvqy40m5EBlIDpusDKZS08xqUoXz\nnFRHRfyXfI/BX1JefhmEEhzyazWvj0R8ZA0LfF5o0R/3P2QIvYuJhiYcIBwN\ntdd+vBxGRDJJuYQCvkXpJyeDoAyuqrL1xzItlpfOBRbB6Ed9THWLlIP8qqU7\nwfb+4esfqs7RxV/hOxjMCTLDEAIZNCPP7puq31KFmk49B/b0bb1yYNt7oQvg\nUT1ZzRVps/UgFJX/RdYi+aaYKpd2AyOSXbwS78lE8ck9cEFm5jR1Mq17MVIQ\nazcZrlHRGeFQjIGwIA/nsPLrvG9+kqZKddDqvvTJWbmx8wNEwbj/YWtOgGop\nhaI9mHTQmjdXgWfiZQ7lANOlNjfkWMXDapXYWCyWE/GeGmsa/QLAi6Epsh+F\nUbzcCeH/e+mWHOSctN90Hj/Nfyyyvu9VxHltOYCPdYx/a7OtNQbs8ZKGuZRv\nklky/XQkiDUHz7Xcm7SkgZJmizcxWr0954SHUVwC/VChNNy54R9iYWT6mUaf\nV/ExsYaQhL657PZXDPM/T9Zc7zeeWikxJdAwHJrTQ8AKmNS0qWqW5+pru6fT\nmE7d\r\n=4vkO\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIEJ8dIBPZ0BehXwYrWuEYvgqsBzjy7loBBbDyBHu1TakAiAwnOFo4grpxehXiVPII4WQ8k9lV7ymw3NuO6rnn/7Eog=="}]},"maintainers":[{"name":"djunger02","email":"junger.da@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/redux-set-state_1.0.5_1544510242733_0.6862101895908765"},"_hasShrinkwrap":false}},"time":{"created":"2018-09-12T00:11:44.584Z","1.0.0":"2018-09-12T00:11:44.908Z","modified":"2022-04-05T04:50:44.066Z","1.0.1":"2018-09-12T00:17:08.227Z","1.0.2":"2018-09-12T19:15:11.511Z","1.0.3":"2018-09-12T19:19:02.871Z","1.0.5":"2018-12-11T06:37:22.855Z"},"maintainers":[{"name":"djunger02","email":"junger.da@gmail.com"}],"description":"A generic reducer that might be all you need","homepage":"https://github.com/danjunger/redux-set-state#readme","repository":{"type":"git","url":"git+https://github.com/danjunger/redux-set-state.git"},"author":{"name":"Dan Junger"},"bugs":{"url":"https://github.com/danjunger/redux-set-state/issues"},"license":"MIT","readme":"Redux Set State\n=============\n\nA generic reducer and action creator for Redux.\n\n[![build status](https://img.shields.io/travis/reduxjs/redux-thunk/master.svg?style=flat-square)](https://travis-ci.org/danjunger/redux-set-state)\n\n```js\nyarn add @djunger02/redux-set-state\n```\n\n## What is it?\n\nThis package provides a generic reducer function and its associated action creator.\n\n\n## Motivation\n\nRedux is great, and I'm a big fan of it, but some folks get very tired of creating distinct actions and their corresponding reducer cases for every interaction in your app.  For example, I have seen many projects that have many action creators that look like these:\n\n```js\nconst TOGGLE_THING = 'TOGGLE_THING'\nfunction toggleThing() {\n  return {\n    type: TOGGLE_THING\n  }\n}\n```\n\n```js\nconst INCREMENT_COUNTER = 'INCREMENT_COUNTER'\nfunction increment() {\n  return {\n    type: INCREMENT_COUNTER\n  }\n}\n```\n\n```js\nconst LOGIN_USER = 'LOGIN_USER'\nfunction login(userMeta) {\n  return {\n    type: LOGIN_USER,\n    payload: userMeta\n  }\n}\n```\n\nThese actions are highly specific and not re-usable, so they quickly accumulate and generate a lot of cruft.  However, what they all have in common is that they each want to set a piece of data to a specific part of the Redux store.  This module provides a single reducer and action creator that can be used for all of these cases and many more.\n\n\n## Do I Need This?\n\nIf you’re not sure whether you need it, you probably don’t.  If you're tired of creating unique action creators and reducer cases for every action in your app, give it a try.\n\n\n## Installation\n\n```\nyarn add @djunger02/redux-set-state\n```\n\nThen, add the reducer to your app:\n\n```js\nimport { createStore } from 'redux';\nimport { createReducer } from '@djunger02/redux-set-state';\n\nconst initialState = {\n  todos: {},\n  isLoggedIn: false\n};\nconst reducer = createReducer(initialState);\nconst store = createStore(\n  reducer,\n  /* applyMiddleware(...) */\n);\n```\n\nThen, whenever you have a need to update a part of the store, use the provided action creator:\n\n```js\ndispatch(setState('isLoggedIn', true)); // set the top level property 'isLoggedIn' to true\ndispatch(setState('user', { email: 'user@example.com', name: 'Jane User' })); // set the email and name properties onto the user object\ndispatch(setState('models', { '3': {id: 3, ...}, '4': {id: 4, ...} })); // set a number of models into the store\ndispatch(setState('models.3', { id: 3, ... })); // overwrite a single model into the store\ndispatch(setState('foos.3.bars.4', { id: 3, ... })); // overwrite a single nested model into the store\n\ndispatch(mergeState('user', { name: 'Jane User' })); // merge the name properties onto the user object\ndispatch(mergeState('models', { '3': {...}, '4': {...} })); // merge a number of models into the store\n```\n\n## Caveats\n\nThis module works best if you avoid using arrays in your store data structure because then you would have to care about array indexes while merging data.  The reducer uses the excellent library [updeep](https://github.com/substantial/updeep) to perform immutable updates to your store object.  Updeep handles deeply nested merges, so you never have to worry about whether part of your store path exists or not!\n\n\n## License\n\nMIT\n","readmeFilename":"README.md"}