The site content lives in src/content/docs/, which is also opened in Obsidian via the Vault CMS
workflow. Everything here keeps that workflow non-fragile — no imports required, no JSX unless
you want it.
Pick per note
.md — plain Markdown. Perfect for Obsidian. Cannot use <Aside>, <Tabs>, <Card> JSX
directly, but you can use the directive syntax (:::note) which renders the same asides.
.mdx — Markdown + JSX. Everything on the site’s markdown-showcase
page is available. Obsidian shows the import lines as raw text — ignore them, editing body text
still works.
My default
Content posts — write in .md with directive-syntax asides. Simplest, safest, Obsidian-native.
Reference / landing pages — use .mdx when you need Cards, Tabs, Steps, LinkCards.
Copy this into a new note in Obsidian, save with a .md extension, and it will build without any
JSX or imports.
description : One-line summary that shows in search and previews.
tags : [ kubernetes , notes ]
# Optional — flip on for time-sensitive posts:
# draft: true # keep drafts out of Recent Posts
Intro paragraph. Regular Markdown works exactly as Obsidian previews it.
- ** Bold ** , * italic * , `inline code` , [ links ] ( https://example.com )
- Task lists: - [ ] not done · - [ x ] done
## Asides (Starlight extension)
Use the ** directive syntax ** — plain Markdown, no imports needed:
This renders as a note callout on the site. Obsidian shows it as text — that's fine.
```yaml title="deployment.yaml"
Put images beside the note or in `src/assets/…` . Plain Markdown syntax works — Astro optimizes them:
![ Description ] ( ./assets/diagram.png )
A[Idea] --> B[Draft] --> C[Publish]
Every field except title is optional. The schema (see
frontmatter reference ) is deliberately permissive:
date: z . coerce . date () . optional (),
pubDate: z . coerce . date () . optional (),
draft: z . boolean () . optional (),
tags: z . array (z . string ()) . optional (),
showDate: z . boolean () . optional (),
So a note with just a title builds fine:
Rename to .mdx and import at the top:
import { Card, Tabs, TabItem } from ' @astrojs/starlight/components ' ;
< TabItem label = " One " > Content A </ TabItem >
< TabItem label = " Two " > Content B </ TabItem >
Obsidian will show the import line as text. Ignore it — the file still saves and syncs cleanly.
If you’d rather stay in plain .md, mimic Tabs with headings and mimic Cards with blockquotes:
> ** Best for: ** simple deploys
> ** Best for: ** complex deploys
It’s not as pretty, but it’s Obsidian-perfect.