Disable pre-ssg getPosts
Some checks reported errors
continuous-integration/drone/push Build was killed
Some checks reported errors
continuous-integration/drone/push Build was killed
This commit is contained in:
parent
6240a4104a
commit
974cee1cf4
@ -1,8 +1,9 @@
|
|||||||
---
|
---
|
||||||
import BaseLayout from "@/layouts/BaseLayout.astro";
|
import BaseLayout from "@/layouts/BaseLayout.astro";
|
||||||
import { getPosts } from "@/utils/payload";
|
//import { getPosts } from "@/utils/payload";
|
||||||
|
//const posts = await getPosts();
|
||||||
|
|
||||||
import '../styles/global.css'
|
import '../styles/global.css'
|
||||||
const posts = await getPosts();
|
|
||||||
---
|
---
|
||||||
|
|
||||||
<BaseLayout title="Astroad">
|
<BaseLayout title="Astroad">
|
||||||
@ -22,7 +23,7 @@ const posts = await getPosts();
|
|||||||
</p>
|
</p>
|
||||||
<h2 class="mt-6 font-bold text-2xl">Posts</h2>
|
<h2 class="mt-6 font-bold text-2xl">Posts</h2>
|
||||||
<div class="flex gap-4 mt-3 flex-wrap">
|
<div class="flex gap-4 mt-3 flex-wrap">
|
||||||
{
|
<!-- {
|
||||||
posts.length > 0 ? (
|
posts.length > 0 ? (
|
||||||
posts.map((post) => (
|
posts.map((post) => (
|
||||||
<a href={`/posts/${post.id}/`}>
|
<a href={`/posts/${post.id}/`}>
|
||||||
@ -39,7 +40,7 @@ const posts = await getPosts();
|
|||||||
) : (
|
) : (
|
||||||
<p>Add Posts in Payloadcms</p>
|
<p>Add Posts in Payloadcms</p>
|
||||||
)
|
)
|
||||||
}
|
} -->
|
||||||
</div>
|
</div>
|
||||||
</main>
|
</main>
|
||||||
</BaseLayout>
|
</BaseLayout>
|
||||||
|
Loading…
Reference in New Issue
Block a user