mirror of
https://github.com/TheTaz25/denis.ergin.git
synced 2025-07-06 08:18:49 +00:00
fix: wrong content generation after upgrade
content was generated into de folder
This commit is contained in:
parent
83e75c3f18
commit
3d0fecca5d
6 changed files with 7 additions and 14 deletions
|
@ -1,14 +1,8 @@
|
||||||
import { defineCollection, z } from 'astro:content';
|
import { defineCollection, z } from 'astro:content';
|
||||||
|
import { glob } from 'astro/loaders';
|
||||||
const skillCollection = defineCollection({
|
|
||||||
type: 'data',
|
|
||||||
schema: z.object({
|
|
||||||
skills: z.array(z.string())
|
|
||||||
}),
|
|
||||||
});
|
|
||||||
|
|
||||||
const dhbwCollection = defineCollection({
|
const dhbwCollection = defineCollection({
|
||||||
type: 'content',
|
loader: glob({ pattern: '*.(mdx|md)', base: './src/content/dhbw/de' }),
|
||||||
schema: z.object({
|
schema: z.object({
|
||||||
title: z.string(),
|
title: z.string(),
|
||||||
tags: z.array(z.string()),
|
tags: z.array(z.string()),
|
||||||
|
@ -23,7 +17,6 @@ const homeCollection = defineCollection({
|
||||||
})
|
})
|
||||||
|
|
||||||
export const collections = {
|
export const collections = {
|
||||||
'skills': skillCollection,
|
|
||||||
'dhbw': dhbwCollection,
|
'dhbw': dhbwCollection,
|
||||||
'home': homeCollection,
|
'home': homeCollection,
|
||||||
}
|
}
|
|
@ -4,7 +4,7 @@ tags:
|
||||||
- "dhbw"
|
- "dhbw"
|
||||||
- "web"
|
- "web"
|
||||||
- "engineering"
|
- "engineering"
|
||||||
slug: "web-engineering-project-25-checklist"
|
id: "web-engineering-project-25-checklist"
|
||||||
staticPath: "knowledge-base/dhbw/"
|
staticPath: "knowledge-base/dhbw/"
|
||||||
show: true
|
show: true
|
||||||
order: 3
|
order: 3
|
||||||
|
|
|
@ -7,7 +7,7 @@ tags:
|
||||||
- "html"
|
- "html"
|
||||||
- "css"
|
- "css"
|
||||||
- "javascript"
|
- "javascript"
|
||||||
slug: "web-engineering-i-s2"
|
id: "web-engineering-i-s2"
|
||||||
staticPath: "knowledge-base/dhbw/"
|
staticPath: "knowledge-base/dhbw/"
|
||||||
show: true
|
show: true
|
||||||
order: 2
|
order: 2
|
||||||
|
|
|
@ -7,7 +7,7 @@ tags:
|
||||||
- "html"
|
- "html"
|
||||||
- "css"
|
- "css"
|
||||||
- "javascript"
|
- "javascript"
|
||||||
slug: "web-engineering-i"
|
id: "web-engineering-i"
|
||||||
staticPath: "knowledge-base/dhbw/"
|
staticPath: "knowledge-base/dhbw/"
|
||||||
show: true
|
show: true
|
||||||
order: 1
|
order: 1
|
||||||
|
|
|
@ -7,7 +7,7 @@ tags:
|
||||||
- "html"
|
- "html"
|
||||||
- "css"
|
- "css"
|
||||||
- "javascript"
|
- "javascript"
|
||||||
slug: "web-engineering-ii"
|
id: "web-engineering-ii"
|
||||||
staticPath: "knowledge-base/dhbw/"
|
staticPath: "knowledge-base/dhbw/"
|
||||||
show: false
|
show: false
|
||||||
order: 3
|
order: 3
|
||||||
|
|
|
@ -28,7 +28,7 @@ const dhbwModules = await getCollection('dhbw', (module) => module.data.show);
|
||||||
{dhbwModules
|
{dhbwModules
|
||||||
.sort((e1, e2) => (e1.data.order - e2.data.order))
|
.sort((e1, e2) => (e1.data.order - e2.data.order))
|
||||||
.map((module) => (
|
.map((module) => (
|
||||||
<Card to={`/${module.data.staticPath}${module.slug}`} class="module-card">
|
<Card to={`/${module.data.staticPath}${module.id}`} class="module-card">
|
||||||
<span class="card-title">{module.data.title}</span>
|
<span class="card-title">{module.data.title}</span>
|
||||||
<Icon name="arrow" class="arrow" />
|
<Icon name="arrow" class="arrow" />
|
||||||
</Card>
|
</Card>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue