(categoryId: number)
| 246 | } |
| 247 | |
| 248 | export async function getPostsByCategory(categoryId: number): Promise<Post[]> { |
| 249 | return wordpressFetch<Post[]>("/wp-json/wp/v2/posts", { |
| 250 | categories: categoryId, |
| 251 | }); |
| 252 | } |
| 253 | |
| 254 | export async function getPostsByTag(tagId: number): Promise<Post[]> { |
| 255 | return wordpressFetch<Post[]>("/wp-json/wp/v2/posts", { tags: tagId }); |
nothing calls this directly
no test coverage detected