Markdown View
@sushindustries/uiRenders Markdown with callouts, CSS-only tabs, custom blocks and highlighted code.
Renders a whole Markdown document - headings, callouts, CSS-only tabs, custom blocks and highlighted code - as the template layer every content file on this site is written against. Reach for it wherever raw Markdown, not JSX, needs to become a page: posts, component docs, package READMEs.
tanstacktanstack add https://adamjurek.com/r/tanstack/markdown-view.jsonpnpm dlx shadcn@latest add https://adamjurek.com/r/shadcn/markdown-view.jsonWhy it is built this way
Content on this site is .md, not TSX, which only works if Markdown can
reach past paragraphs and lists - the docs extensions add callouts and
tabbed sections, and blocks lets a page map a comment-fenced block to a
live React component without this package knowing what that component is.
Parsing and syntax highlighting both run synchronously, so a whole document
renders during SSR with no client JavaScript and nothing to re-highlight on
hydration.
The parser's trust boundary is what makes rendering author content safe at all: it emits a bounded AST rather than passing raw HTML through, so a document cannot inject markup.
What it does not do
An unmatched block name or reference mention is not an error - it falls back
quietly, rendering its children as plain prose or plain <code>. That is
deliberate but it means a typo in a block's name looks identical to the
block doing nothing.
Install commands are not written here
Anything in packages/ui/registry.ts gets its TanStack and shadcn commands
attached automatically, so there is nothing to keep in sync.
Install
tanstack add https://adamjurek.com/r/tanstack/markdown-view.jsonpnpm dlx shadcn@latest add https://adamjurek.com/r/shadcn/markdown-view.jsonpnpm add @sushindustries/ui @sushindustries/atomsWhat you get
| Version | 0.1.0 |
| Category | content · Rendering |
| Files | markdown-view.tsx, markdown-blocks.tsx |
| Dependencies | @tanstack/markdown@0.0.13 |
| Also installs | code-blockCode BlockA highlighted code slab with the CLI's colours, a lit top edge, and a copy button that confirms in place.@sushindustries/ui · content, referenceReferenceAn inline mention that carries a hover card: title, summary and meta for the thing it names, raised by CSS alone.@sushindustries/ui · content |
| Tags | markdown, highlight, ssr |