mirror of
https://github.com/kamranahmedse/developer-roadmap.git
synced 2025-01-17 14:18:17 +01:00
fix: showcase roadmap index (#6283)
This commit is contained in:
parent
bff7c4203a
commit
b35ce9ab60
@ -30,5 +30,10 @@ export function roadmapApi(context: APIContext) {
|
||||
searchParams,
|
||||
);
|
||||
},
|
||||
isShowcaseRoadmap: async function (slug: string) {
|
||||
return api(context).get<{
|
||||
isShowcase: boolean;
|
||||
}>(`${import.meta.env.PUBLIC_API_URL}/v1-is-showcase-roadmap/${slug}`);
|
||||
},
|
||||
};
|
||||
}
|
||||
|
@ -4,13 +4,19 @@ import { CustomRoadmap } from '../../components/CustomRoadmap/CustomRoadmap';
|
||||
import { SkeletonRoadmapHeader } from '../../components/CustomRoadmap/SkeletonRoadmapHeader';
|
||||
import Loader from '../../components/Loader.astro';
|
||||
import ProgressHelpPopup from '../../components/ProgressHelpPopup.astro';
|
||||
import { roadmapApi } from '../../api/roadmap';
|
||||
|
||||
export const prerender = false;
|
||||
|
||||
const { customRoadmapSlug } = Astro.params;
|
||||
|
||||
const roadmapClient = roadmapApi(Astro);
|
||||
const { response, error } = await roadmapClient.isShowcaseRoadmap(
|
||||
customRoadmapSlug!,
|
||||
);
|
||||
---
|
||||
|
||||
<BaseLayout title='Roadmaps'>
|
||||
<BaseLayout title='Roadmaps' noIndex={!response?.isShowcase}>
|
||||
<ProgressHelpPopup />
|
||||
<div>
|
||||
<div class='flex min-h-[550px] flex-col'>
|
||||
|
Loading…
x
Reference in New Issue
Block a user