Skip to content

Commit

Permalink
docs: update get contents
Browse files Browse the repository at this point in the history
  • Loading branch information
aliosmandev committed May 25, 2024
1 parent 7a87651 commit 3ae0ee1
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 9 deletions.
4 changes: 2 additions & 2 deletions apps/docs/content/docs/contents.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@ async function getContents() {
import { postivaClient } from "@/libs/postiva";
import { GetContentsType, ContentStatusEnum } from '@postiva/client'

async function getContentsWithQuery({ query, type=ContentStatusEnum.published, category }: GetContentsType) {
async function getContentsWithQuery({ query, type=ContentStatusEnum.published, categories }: GetContentsType) {
try {
const contents = await client.getContents({ query, type, category });
const contents = await client.getContents({ query, type, categories });
console.log(contents);
} catch (error) {
console.error('Error fetching contents:', error);
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"start": "next start"
},
"dependencies": {
"@postiva/client": "0.0.27",
"@postiva/client": "workspace:*",
"fumadocs-core": "^11.0.4",
"fumadocs-docgen": "^1.0.1",
"fumadocs-mdx": "^8.2.13",
Expand Down
8 changes: 2 additions & 6 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 3ae0ee1

Please sign in to comment.