Segue erro apresentado e código do INDEX PAGES e BUSCADOR
Failed to compile.
/Users/familiatorreslemos/Desktop/AluraReactapp/src/pages/index.tsx TypeScript error in /Users/familiatorreslemos/Desktop/AluraReactapp/src/pages/index.tsx(24,15): Type '{ busca: string; setBusca: Dispatch<SetStateAction>; }' is not assignable to type 'IntrinsicAttributes'. Property 'busca' does not exist on type 'IntrinsicAttributes'. TS2322
22 | <h3 className={styles.cardapio__titulo}> Cardápio </h3>
23 |
24 | | ^ 25 | 26 | 27 |
INDEX PAGES import styles from "./Cardapio.module.scss"; import{ReactComponent as Logo } from "..//assets/logo.svg"; import Buscador from "./Buscador"; import {useState} from "react";
export default function Cardapio (){
const [busca, setBusca] = useState("") ;
return(
<main>
<nav className={styles.menu} > </nav>
<Logo/>
<header className={styles.header}>
<div className={styles.header__text}>Restaurante Jones . Aproveite nossos pratos exclusivos!</div>
</header>
<section className={styles.cardapio}>
<h3 className={styles.cardapio__titulo}> Cardápio </h3>
<Buscador busca ={busca} setBusca={setBusca} />
</section>
</main>
)
}
INDEX BUSCADOR
import React from 'react';
interface Props { busca: string, setBusca: React.Dispatch<React.SetStateAction>;
}
export default function Buscador() {
return
}