feat(blog): redesign post detail experience
This commit is contained in:
@@ -89,6 +89,16 @@ export async function getPublicPost(slug: string) {
|
||||
});
|
||||
}
|
||||
|
||||
export async function getRecommendedPosts(slug: string, limit = 3) {
|
||||
return requestJson<Types.PostListSchema[]>(
|
||||
`/api/blog/posts/${encodeURIComponent(slug)}/recommended`,
|
||||
{
|
||||
params: { limit },
|
||||
revalidate: DEFAULT_REVALIDATE_SECONDS,
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
export async function getPublicEvents(options?: { search?: string; limit?: number }) {
|
||||
const search = options?.search?.trim();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user