Converting Class component to functional component – Reactjs
I would like to convert React class component to functional component. const remoteVideoref = useRef(null); this.pc.ontrack = (e) => { this.remoteVideoref.current.srcObject = e.streams[0] } Is this the correct way of doing it? const remoteVideoref = useRef(null); this.pc.ontrack = (e) =>…