skip to Main Content

Javascript – Rendering Twice

I tried to build a video chat application using React and peerjs. and below is pieces of code that handles it. const randomPeerId = uuidv4(); const peer = new Peer(randomPeerId); export function VideoCall() { const [peerId, setPeerId] = useState(""); useEffect(()=>{…

VIEW QUESTION

Reactjs – why my Import functions are not working in react?

IN header.js function header(){ return(<div className="header"><header><h1>Header Content</h1></header></div>); } export default header; IN footer.js function footer(){ return(<div className="footer"><footer>copyright 2022-23</footer></div>) } export default footer; **IN App.js** import React from 'react'; import header from './header'; import footer from './footer'; function App() { return…

VIEW QUESTION
Back To Top
Search