Skip to content

Instantly share code, notes, and snippets.

View dandelionadia's full-sized avatar
👾

Nadiia Ridko dandelionadia

👾
  • Prague, Czech Republic
View GitHub Profile
class Person extends Component {
constructor(props) {
super(props);
this.inputElementRef = React.creatRef();
}
componentDidMount() {
this.inputElementRef.current.focus();
}
import React, { useEffect, useRef, useContext } from "react";
import { AuthContext } from "../../context/auth-context";
export const Cockpit = (props) => {
const authContext = useContext(AuthContext);
console.log(authContext.authenticated);
return (
<>