feat: add strapi cms data
- add types - add layout data loading - add mapping functions - add CmsComponent - remove image
This commit is contained in:
@@ -1,15 +1,11 @@
|
||||
<script lang="ts">
|
||||
import content from '$lib/data/data.json';
|
||||
import type { Data } from '$lib/types/data';
|
||||
import Profile from '$lib/components/Profile.svelte';
|
||||
import Projects from '$lib/components/Projects.svelte';
|
||||
import Skills from '$lib/components/Skills.svelte';
|
||||
import Contact from '$lib/components/Contact.svelte';
|
||||
import type { PageProps } from '../../.svelte-kit/types/src/routes/$types';
|
||||
import CmsComponent from '$lib/components/cms/CmsComponent.svelte';
|
||||
|
||||
let data: Data = content;
|
||||
let { data }: PageProps = $props();
|
||||
console.debug(data)
|
||||
</script>
|
||||
|
||||
<Profile {...data.profile} />
|
||||
<Projects {...data.projects} />
|
||||
<Skills {...data.skills} />
|
||||
<Contact {...data.contact} />
|
||||
{#each data.components as component, index (index)}
|
||||
<CmsComponent {...component} />
|
||||
{/each}
|
||||
Reference in New Issue
Block a user