Promise all fetching
@@ -285,16 +285,16 @@ export const HomePage = () => {
export const getStaticProps: GetStaticProps<Props> = async ({ params }) => {
const language = params.lang as string;
- await prefetchSharedQueries(language);
-
- await queryKeynotesSection({
+ await Promise.all([
+ prefetchSharedQueries(language),
+ queryKeynotesSection({
code: process.env.conferenceCode,
- });
-
- await queryIndexPage({
+ }),
+ queryIndexPage({
language,
code: process.env.conferenceCode,
- });
+ }),
+ ]);
return addApolloState({
props: {},
