Files
theater-ziefen-website/tina/__generated__/config.prebuild.jsx
T
Johannes Gasser ac2d1f25e5 Fix Astro.glob deprecation warnings
Replace deprecated Astro.glob with import.meta.glob in all pages:
- src/pages/index.astro: Updated homepage to use import.meta.glob
- src/pages/blog/index.astro: Updated blog listing page
- Updated package.json with separate build commands

Changes use import.meta.glob with eager loading and properly extract
slugs from file paths for routing.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2026-01-28 17:52:36 +01:00

101 lines
2.2 KiB
React

// tina/config.ts
import { defineConfig } from "tinacms";
var config_default = defineConfig({
branch: process.env.TINA_BRANCH || "main",
clientId: process.env.TINA_CLIENT_ID || "",
token: process.env.TINA_TOKEN || "",
build: {
outputFolder: "admin",
publicFolder: "public"
},
media: {
tina: {
mediaRoot: "images",
publicFolder: "public"
}
},
schema: {
collections: [
{
name: "post",
label: "Blog Posts",
path: "content/blog",
format: "mdx",
fields: [
{
type: "string",
name: "title",
label: "Title",
isTitle: true,
required: true
},
{
type: "datetime",
name: "date",
label: "Publication Date",
required: true
},
{
type: "string",
name: "excerpt",
label: "Excerpt",
required: true,
description: "Short summary of the blog post"
},
{
type: "image",
name: "coverImage",
label: "Cover Image",
description: "Featured image for the blog post"
},
{
type: "rich-text",
name: "body",
label: "Body",
isBody: true,
required: true
}
],
defaultItem: () => {
return {
title: "New Blog Post",
date: (/* @__PURE__ */ new Date()).toISOString(),
excerpt: ""
};
}
},
{
name: "page",
label: "Pages",
path: "content/pages",
format: "mdx",
fields: [
{
type: "string",
name: "title",
label: "Title",
isTitle: true,
required: true
},
{
type: "string",
name: "description",
label: "Description",
description: "Meta description for SEO"
},
{
type: "rich-text",
name: "body",
label: "Content",
isBody: true,
required: true
}
]
}
]
}
});
export {
config_default as default
};