Quick Reference
Installation
1pnpm add -D sveadBasic Usage
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 Case | Component | Schema Type |
|---|---|---|
| Basic SEO | Head | N/A |
| Blog Post | Both | BlogPosting |
| Article | Both | Article |
| News Article | Both | NewsArticle |
| Product Page | Both | Product |
| Recipe | Both | Recipe |
| Event | Both | Event |
| FAQ | Both | FAQPage |
| Tutorial | Both | HowTo |
| Video | Both | VideoObject |
| Course | Both | Course |
| Breadcrumbs Only | SchemaOrg | BreadcrumbList |
For more information and full documentation, visit the Svead GitHub repository.