-
Currently in version 6 hit is a directly exported member from interface SuggestionProps {
hit: Hit;
handleMouseEnter: (e: React.SyntheticEvent<HTMLElement, Event>) => void;
handleMouseLeave: (e: React.SyntheticEvent<HTMLElement, Event>) => void;
} |
Beta Was this translation helpful? Give feedback.
Answered by
dhayab
Oct 31, 2024
Replies: 1 comment 2 replies
-
Hi, you'll be able to import this type from import type { Hit } from 'instantsearch.js';
interface SuggestionProps {
hit: Hit;
/* ... */
} It also is a generic type, so you can enrich it with your records type definition. You can find an example on our React InstantSearch getting-started code sandbox. |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
dhayab
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi, you'll be able to import this type from
instantsearch.js
like this:It also is a generic type, so you can enrich it with your records type definition. You can find an example on our React InstantSearch getting-started code sandbox.