import React, {useState} from 'react';
import meal05 from "./assets/images/time.png";
const App = () => {
let time = new Date().toLocaleTimeString('en-US');
const[atime,setAtime] = useState(time);
const UpdateTime = ()=>{
time = new Date().toLocaleTimeString('en-US');
setAtime(time);
}
setInterval(UpdateTime,5000)
return (
<div>
<section className="home" >
<div className="image">
<img src={meal05} alt=""></img>
</div>
<div className="content">
<h3> {atime} </h3>
</div>
</section>
</div>
)
}
export default App