{"repo":"inmagik/use-eazy-auth","free":true,"listed":false,"github":"https://github.com/inmagik/use-eazy-auth","clone":"git clone https://github.com/inmagik/use-eazy-auth.git","description":"React hooks for handling auth stuff","language":"TypeScript","stars":57,"topics":["react","hooks","react-hooks","auth","authentication","typescript"],"license":"MIT","category":"auth-billing-email","readme_excerpt":"use-eazy-auth React components and hooks to deal with token based authentication This project takes the main concepts and algorithms (but also the name) from the eazy-auth library, and aims at providing equivalent functionality in contexts where the usage of eazy-auth with its strong dependency on redux and redux-saga is just too constraining. Installation Api Component The top level component where you are able to configure authentication behaviours. Token based authentication is based on the usage of a token as a proof of identity. As such, the library has to deal with acquiring a token, storing it for later use, validating it, refreshing it when it expires, and deleting it when no refresh is possible or the token is revoked. Moreover, the token is strictly tied to a user (as it is the proof of his identity), and so it is usually a good idea to keep the user object around while the token is valid. This concepts are common to the majority of token based authentication system, even if implementation of them can be really different. Given this, use-eazy-auth gives you full customization freedom to integrate with your specific implementation and to tailor its own behaviours by passing props to the component. The component creates React contexts that are used by any hook, so it is mandatory to make it a common ancestor for all components that need to deal with authentication, and advisable to put it as near as possible to the root of the React application tree. The following pro","default_branch":null,"files":null,"tree":[],"storefront":"/r/inmagik","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/inmagik/use-eazy-auth/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}