strapi integration

This commit is contained in:
nicwands
2026-05-27 15:14:54 -04:00
parent 920a2452dd
commit b85d28c142
4 changed files with 335 additions and 2 deletions

11
pages/index/+data.js Normal file
View File

@@ -0,0 +1,11 @@
import { strapi } from '@strapi/client'
export const data = async () => {
const client = strapi({
baseURL: 'https://cms.takerofnotes.com/api',
auth: import.meta.env.STRAPI_API_TOKEN,
})
const global = client.single('global')
return await global.find()
}