Markdown এ Frontmatter
আপনার md ফাইলের শুরুতে yaml ফরম্যাট ব্যবহার করুন।
---
title: Some title
description: some description
--- md
Svelte এ Frontmatter
Svelte script module এfrontmatter নামক একটি const variable এক্সপোর্ট করুন
/src/routes/foo/+page.svelte
<script module>
export const
const frontmatter: {
title: string;
description: string;
}
frontmatter = {
title: stringtitle: 'Some title',
description: stringdescription: 'Some description',
}
</script> svelte
Markdown এ Frontmatter অ্যাক্সেস করা
fm variable ব্যবহার করুন:
Frontmatter of this page is:
${$.escape(JSON.stringify(fm, null, 2))}
Frontmatter of this page is:
<pre>
{JSON.stringify(fm, null, 2)}
</pre> md
সাইট Frontmatter
প্রত্যেকটি +page.md ফাইল থেকে অ্যাক্সেস করা যাবে এমন ব্যাপক frontmatter
interface SiteConfig {
SiteConfig.title?: string | undefinedtitle?: string
SiteConfig.description?: string | undefineddescription?: string
} ts