File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ function MyTimer({ expiryTimestamp }) {
3333 pause ,
3434 resume ,
3535 restart ,
36- } = useTimer ({ expiryTimestamp, onExpire : () => console .warn (' onExpire called' ) });
36+ } = useTimer ({ expiryTimestamp, autoStart : true , onExpire : () => console .warn (' onExpire called' ) });
3737
3838
3939 return (
@@ -73,8 +73,10 @@ export default function App() {
7373| key | Type | Required | Description |
7474| --- | --- | --- | ---- |
7575| expiryTimestamp | number(timestamp) | YES | this will define for how long the timer will be running |
76+ | autoStart | boolean | No | flag to decide if timer should start automatically |
7677| onExpire | Function | No | callback function to be executed once countdown timer is expired |
7778
79+
7880### Values
7981
8082| key | Type | Description |
You can’t perform that action at this time.
0 commit comments