import { useState } from "react"; import { Link, useHistory } from "react-router-dom"; import Search from "../Search"; const MainNav = () => { const [search, setSearch] = useState({ type: "home", keyword: "" }) const history = useHistory() function searchMovie() { history.push(`/search?title=${search.keyword}`) } return ( ) } export default MainNav