remove unused packages deps and updates example and installation
This commit is contained in:
@@ -1,16 +1,15 @@
|
||||
import React from "react"
|
||||
import ReactDOM from "react-dom"
|
||||
import { useCountdown} from "cubetiq-react-use-countdown"
|
||||
import React from 'react';
|
||||
import ReactDOM from 'react-dom';
|
||||
import { useCountdown } from 'cubetiq-react-use-countdown';
|
||||
|
||||
const App = () => {
|
||||
const { timeleft , start } = useCountdown()
|
||||
return (
|
||||
<div>
|
||||
const { timeleft, start } = useCountdown();
|
||||
return (
|
||||
<div>
|
||||
<button onClick={() => start(10000)}> Start Countdown </button>
|
||||
<h1>Time left: {timeleft}</h1>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
<button onClick={() => start(10000)}>Start Count down </button>
|
||||
<h1>Hellos Ciybt {timeleft}</h1>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
ReactDOM.render(<App /> , document.querySelector("#root"))
|
||||
ReactDOM.render(<App />, document.querySelector('#root'));
|
||||
|
||||
Reference in New Issue
Block a user