import { WatchedMediaCard } from "components/media/WatchedMediaCard"; import { SearchBarInput } from "components/SearchBar"; import { MWMedia, MWMediaType, SearchProviders } from "scrapers"; import { useState } from "react"; import { ThinContainer } from "components/layout/ThinContainer"; import { SectionHeading } from "components/layout/SectionHeading"; import { Icons } from "components/Icon"; import { Loading } from "components/layout/Loading"; import { Tagline } from "components/Text/Tagline"; import { Title } from "components/Text/Title"; export function SearchView() { const [results, setResults] = useState([]); const [search, setSearch] = useState(""); async function runSearch() { const results = await SearchProviders({ type: MWMediaType.MOVIE, searchQuery: search, }); setResults(results); } return (
Because watching legally is boring What movie do you want to watch?
{results.map((v) => ( ))}
); }