useLifecycleLogger
Aboutβ
A react hook that console logs parameters as component transitions through lifecycles.
Installationβ
npm install rooks
Importing the hookβ
import {useLifecycleLogger} from "rooks"
Usageβ
function Demo(props) {
useLifecycleLogger('Demo',props);
// it will log on mount, update and unmount
return null
}
render(<Demo/>)
Codesandbox Examplesβ
Basic Usageβ
Join Bhargav's discord serverβ
You can click on the floating discord icon at the bottom right of the screen and talk to us in our server.