Skip to content
svead

Quick Reference

Installation

Terminal
1pnpm add -D svead

Basic Usage

Svelte
1<script lang="ts">
2	import { Head, SchemaOrg } from 'svead';
3	import type { SeoConfig, SchemaOrgProps } from 'svead';
4
5	const seo_config: SeoConfig = {
6		title: 'Page Title',
7		description: 'Page description',
8		url: 'https://example.com',
9	};
10
11	const schema: SchemaOrgProps['schema'] = {
12		'@type': 'WebPage',
13		name: 'Page Title',
14	};
15</script>
16
17<Head {seo_config} />
18<SchemaOrg {schema} />

Common Patterns Cheatsheet

Use CaseComponentSchema Type
Basic SEOHeadN/A
Blog PostBothBlogPosting
ArticleBothArticle
News ArticleBothNewsArticle
Product PageBothProduct
RecipeBothRecipe
EventBothEvent
FAQBothFAQPage
TutorialBothHowTo
VideoBothVideoObject
CourseBothCourse
Breadcrumbs OnlySchemaOrgBreadcrumbList

For more information and full documentation, visit the Svead GitHub repository.

All documentation