Update logging

This commit is contained in:
Darren Clarke 2025-01-22 17:50:38 +01:00
parent def602c05e
commit 810a333429
39 changed files with 85 additions and 139 deletions

View file

@ -69,19 +69,17 @@ export const getServerSideProps: GetServerSideProps = async (
});
});
}
console.log({ query });
const dataResponse = await client.search({
index: "demo_data",
size: 200,
body: { query },
});
console.log({ dataResponse });
res.props.data = dataResponse.body.hits.hits.map((hit) => ({
id: hit._id,
...hit._source,
}));
console.log({ data: res.props.data });
console.log(res.props.data[0]);
return res;
};