{"_id":"@20i/cognito-react","_rev":"36-990740e192c0c1b4db00818632c818de","name":"@20i/cognito-react","dist-tags":{"latest":"0.1.2-alpha"},"versions":{"0.1.1":{"name":"@20i/cognito-react","version":"0.1.1","author":{"name":"Trevor Dilley"},"license":"COPYRIGHT 20i","_id":"@20i/cognito-react@0.1.1","maintainers":[{"name":"keith20i","email":"keith@twentyideas.com"},{"name":"laurelbenson","email":"laurel@twentyideas.com"},{"name":"mckelveygreg","email":"mckelveygreg@gmail.com"},{"name":"mesqueeb","email":"mesqueeb@gmail.com"},{"name":"wilblack","email":"wil@twentyideas.com"},{"name":"trevordilley","email":"trevor.lee.dilley@gmail.com"},{"name":"nikki-20i","email":"nikki@twentyideas.com"},{"name":"wasredacted","email":"greyson@twentyideas.com"},{"name":"antonioortega","email":"antonio@twentyideas.com"}],"dist":{"shasum":"4793dbe21c8ceece876cf79cef36c13508a38e6e","tarball":"https://registry.npmjs.org/@20i/cognito-react/-/cognito-react-0.1.1.tgz","fileCount":14,"integrity":"sha512-ims3fGPlcxUqYqXJV41zISiSSw1/QtPYNcDCVtZuVITG+KnahZZ6ozBY6B6II1aDKEq3rmHQIy37KTDbcYkAyg==","signatures":[{"sig":"MEUCIH42VQ693XREnSEroCJnSSCUzAcfGcKawlRaHXZG2xqFAiEAy0yB6eNzvC9aD+dTtmTOxYjWVkLGv1dMy/k74Sy97HU=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":249611,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJg96PACRA9TVsSAnZWagAAHzIP/1OZQEJf20sltGMTFui8\nSNN3TydWdwJuTdtEAdIlje/iJtObboKtKtMhLL4UGqUUt4bZju5mFMInBCYR\n9lhiq2gBP0sGMiiYSdvS6wjCiboInKPVgvk976Vpad8+S1BtZSIhXcYkxmfG\nG0GUSMBWPyYYRgJ6PCocR000j+tz5k3uoRaONXKTQpA2gN8Q4Lx1JeYhPCS4\n6LpvJeggbs+4iBLml4lo9fAGny2RF2KIHdFmQgBP21J2QCQ56JKwF9BFlS6x\npyTIQEzimLO3IWT8SzZmJsonylIe4zseuEz4Ch6PGiHtt3PcPCBNAlf3l0Cw\nUxi7Jpp484ZSarBhgNcKBIUwoCmuoHB2GdgQacmP8c4/dt7GTqFVdyg5ZG4T\ntuI7enkSbhV6Feg2E+zKI71zjP/6BRcTOGEALnT4LtSNaGvAkEnFlz7p8xSm\nQfELykXV9ST3l7Hc83RiddQA/gY9SGZs+fE8VQHSOyv+1az9uwbUit2spEem\n1UiYA5IRdhhWButlaSj/i3ONvkr1t5iG92tAGyY+6Z5nLCt0aLkxdHPc/J5y\nth5c2TphxakPbmFH5WitoviX+YBIT/QJL8ffIYO6W15q6UMo1tYWa0e3r+Or\nu9LdWAq9NgsvyuaKhXtU85RzpM3xwywA6x3fo0oioQt7eiYVCFo78/azXzET\nrblW\r\n=1Uuy\r\n-----END PGP SIGNATURE-----\r\n"},"main":"dist/index.js","husky":{"hooks":{"pre-commit":"tsdx lint"}},"module":"dist/cognito-react.esm.js","engines":{"node":">=10"},"scripts":{"lint":"tsdx lint","size":"size-limit","test":"tsdx test","build":"tsdx build","start":"tsdx watch","analyze":"size-limit --why","prepare":"tsdx build"},"typings":"dist/index.d.ts","_npmUser":{"name":"trevordilley","email":"trevor.lee.dilley@gmail.com"},"prettier":{"semi":false,"singleQuote":false},"repository":{"url":"https://github.com/twentyideas/20i-cognito-react.git","type":"git"},"size-limit":[{"path":"dist/cognito-react.cjs.production.min.js","limit":"10 KB"},{"path":"dist/cognito-react.esm.js","limit":"10 KB"}],"description":"A default MUI theme and a function for creating a custom theme by overriding the defaults.","directories":{},"_hasShrinkwrap":false,"devDependencies":{"tsdx":"^0.14.1","axios":"^0.21.1","husky":"^7.0.1","react":"^17.0.2","tslib":"^2.3.0","eslint":"^7.29.0","prettier":"^2.3.1","react-dom":"^17.0.2","size-limit":"^5.0.1","typescript":"^4.3.5","react-query":"3.19.0","@types/react":"^17.0.14","@aws-amplify/auth":"^4.0.3","eslint-config-prettier":"^8.3.0","eslint-plugin-prettier":"^3.4.0","@typescript-eslint/parser":"^4.28.0","@size-limit/preset-small-lib":"^5.0.1","@typescript-eslint/eslint-plugin":"^4.28.0"},"peerDependencies":{"axios":"^0.21.1","react":"^17.0.2","react-dom":"^17.0.2","react-query":"3.19.0","@aws-amplify/auth":"^4.0.3"},"_npmOperationalInternal":{"tmp":"tmp/cognito-react_0.1.1_1626842048609_0.558886557832706","host":"s3://npm-registry-packages"}},"0.1.2-alpha":{"name":"@20i/cognito-react","version":"0.1.2-alpha","author":{"name":"Trevor Dilley"},"license":"COPYRIGHT 20i","_id":"@20i/cognito-react@0.1.2-alpha","maintainers":[{"name":"keith20i","email":"keith@twentyideas.com"},{"name":"laurelbenson","email":"laurel@twentyideas.com"},{"name":"mckelveygreg","email":"mckelveygreg@gmail.com"},{"name":"mesqueeb","email":"mesqueeb@gmail.com"},{"name":"wilblack","email":"wil@twentyideas.com"},{"name":"trevordilley","email":"trevor.lee.dilley@gmail.com"},{"name":"nikki-20i","email":"nikki@twentyideas.com"},{"name":"wasredacted","email":"greyson@twentyideas.com"},{"name":"antonioortega","email":"antonio@twentyideas.com"}],"dist":{"shasum":"2a47691158859936c151938e3c4c693b81fbecb2","tarball":"https://registry.npmjs.org/@20i/cognito-react/-/cognito-react-0.1.2-alpha.tgz","fileCount":14,"integrity":"sha512-G9VM2mnQRFs0wQwCzrivq5U35U+CrRlHNU6RicfPkKXlqLm3SdtKEQBREiZzvF9znI9tucfkuJNUEJvzk+EG2g==","signatures":[{"sig":"MEUCIAxjIUUKSNDZ/bnbKgreFkeMOiHWUGf6ct+B+uUdq0FoAiEA3llzZmqe/JeQhmkIXgq7ZVBKqA/dHIJSNsnev+BdVB4=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":247326,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJg+vMVCRA9TVsSAnZWagAAb4MP/RslDDWbNgNs05Z8QmiZ\nKMjIdHtUptlieeARCmxQxkmMaTQpNQNcSIW0QXSJuMv5ksABobKDoko4BEif\ncMCnz+gCm5x+0jEIA1zZ+fc60LvaSChxncDz8vmoaNom9THN6y8NoizdbsB0\ncuaLDzAJQPT8ay4dGmGydT3Qoj94pNfdolxOiUOEpbZaV8PH1YKrTiup7MdG\nQ2mR9k6WAjOY8I0anzwFXA/lDlcx6g66Tk3CjPpXe4ZQ3M7k/Gv5klPuYRgL\nqgHQdU3kGX0GCKLIJmtY596Hy3r+Oidi7EeqqQp5AXqpMMa3aGzJfSPozGYq\nAs6vV2gOiYoxjDKQO/xI0dBEpPRPZuykRDijDosxNfGR+EB5Wb8tPUU+hnF0\nSjv+hCLNjIb4GFAP5dXGNZwKYmpCRrBZqiUMyJMbtpdOEeD+d99uvYWkNEjj\nMwa2Ei8JeAFW6amNuPT9Nnnskm67lHJmTSCeKqqy0RJOsKmdW6/zx9xxpWE6\nzbHYm2HRN0ioI/3Sovy6+Y1c5TU5guy9lq3ZZVRK6zqT4Ba9JWvI9jd9Jsmh\nEzF5nHKvtQt7FZSSnoP9L1daGFVJr0d/j0jxue5b9wEqPaovu9uJzancrAmK\niy1vWlyAN52gAZ1cz3huK7GGaVBRYUzKAdMJW3s2N/EVRpFtx0b05whqXThT\nzWeM\r\n=v6yh\r\n-----END PGP SIGNATURE-----\r\n"},"main":"dist/index.js","husky":{"hooks":{"pre-commit":"tsdx lint"}},"module":"dist/cognito-react.esm.js","engines":{"node":">=10"},"scripts":{"lint":"tsdx lint","size":"size-limit","test":"tsdx test","build":"tsdx build","start":"tsdx watch","analyze":"size-limit --why","prepare":"tsdx build"},"typings":"dist/index.d.ts","_npmUser":{"name":"trevordilley","email":"trevor.lee.dilley@gmail.com"},"prettier":{"semi":false,"singleQuote":false},"repository":{"url":"https://github.com/twentyideas/20i-cognito-react.git","type":"git"},"size-limit":[{"path":"dist/cognito-react.cjs.production.min.js","limit":"10 KB"},{"path":"dist/cognito-react.esm.js","limit":"10 KB"}],"description":"A nice api to initialize and interact with Cognito from React.","directories":{},"_hasShrinkwrap":false,"devDependencies":{"tsdx":"^0.14.1","axios":"^0.21.1","husky":"^7.0.1","react":"^17.0.2","tslib":"^2.3.0","eslint":"^7.29.0","prettier":"^2.3.1","react-dom":"^17.0.2","size-limit":"^5.0.1","typescript":"^4.3.5","react-query":"3.19.0","@types/react":"^17.0.14","@aws-amplify/auth":"^4.0.3","eslint-config-prettier":"^8.3.0","eslint-plugin-prettier":"^3.4.0","@typescript-eslint/parser":"^4.28.0","@size-limit/preset-small-lib":"^5.0.1","@typescript-eslint/eslint-plugin":"^4.28.0"},"peerDependencies":{"axios":"^0.21.1","react":"^17.0.2","react-dom":"^17.0.2","react-query":"3.19.0","@aws-amplify/auth":"^4.0.3"},"_npmOperationalInternal":{"tmp":"tmp/cognito-react_0.1.2-alpha_1627058965331_0.7623466603511257","host":"s3://npm-registry-packages"}}},"time":{"created":"2021-07-21T04:34:08.608Z","modified":"2025-09-04T21:03:46.332Z","0.1.1":"2021-07-21T04:34:08.822Z","0.1.2-alpha":"2021-07-23T16:49:25.507Z"},"author":{"name":"Trevor Dilley"},"license":"COPYRIGHT 20i","repository":{"url":"https://github.com/twentyideas/20i-cognito-react.git","type":"git"},"description":"A nice api to initialize and interact with Cognito from React.","maintainers":[{"email":"wil@twentyideas.com","name":"wilblack"},{"email":"trevor.lee.dilley@gmail.com","name":"trevordilley"},{"email":"greyson@twentyideas.com","name":"wasredacted"},{"email":"james@twentyideas.com","name":"james-20i"},{"email":"npm-service@twentyideas.com","name":"20i-npm-service"},{"email":"hiddnist@gmail.com","name":"hiddn"},{"email":"keeto@twentyideas.com","name":"keeto-20i"},{"email":"gelferstone@gmail.com","name":"gelfer"},{"email":"tony@twentyideas.com","name":"tony20i"},{"email":"mook@twentyideas.com","name":"mook-20i"},{"email":"orianna@twentyideas.com","name":"orianna-20i"}],"readme":"# @20i/cognito-react\n\nA nice api to initialize and interact with Cognito from\nReact.\n\n## Peer dependencies\n\n```\n    \"@aws-amplify/auth\": \"^4.0.3\",\n    \"react\": \"^17.0.2\",\n    \"react-query\": \"3.19.0\",\n    \"axios\": \"^0.21.1\",\n    \"react-dom\": \"^17.0.2\"\n```\n\n## Installation\n\n```shell\nnpm login\nnpm i @20i/20i-cognito-react\n```\n\n## Usage\n\n```typescript\nimport { Cognito } from \"@20i/cognito-react\"\nimport config from \"./config\"\n\nconst { cognito } = config\nCognito.configure(cognito)\n\nconst hooks = Cognito.Hooks((authUser: CognitoUser) => {\n  const user = getUser(authUser)\n  // Do stuff with the Cognito AuthUser to get the rest of the user data\n  // (Like retrieve it from the DB, etc) \n  return user\n})\n\n// The hooks returned from Cognito.Hooks will use the supplied lambda\n// to retrieve the user in their respective logicks\nexport const useUser = hooks.useUser\nexport const useAuthUser = hooks.useAuthUser\n```\n","readmeFilename":"README.md"}