style: specify source of apollo state interface

Signed-off-by: Dmytro Stanchiev <git@dmytros.dev>
This commit is contained in:
2025-09-17 19:00:13 -04:00
parent 63683593e4
commit 257edf394c

View File

@@ -5,7 +5,7 @@ type SearchListing = {
listingLink: string;
};
interface ApolloState {
interface ApolloSearchState {
[key: string]: {
[key: string]: unknown;
url: string;
@@ -33,7 +33,8 @@ function extractSearchListingsFromNextData(htmlString: string) {
return [];
}
const jsonData = JSON.parse(nextData.textContent);
const apolloState: ApolloState = jsonData.props.pageProps.__APOLLO_STATE__;
const apolloState: ApolloSearchState =
jsonData.props.pageProps.__APOLLO_STATE__;
const listingsKeys: string[] = [];