惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

S
SegmentFault 最新的问题
Jina AI
Jina AI
罗磊的独立博客
V
Visual Studio Blog
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
J
Java Code Geeks
U
Unit 42
Microsoft Azure Blog
Microsoft Azure Blog
B
Blog RSS Feed
爱范儿
爱范儿
酷 壳 – CoolShell
酷 壳 – CoolShell
Last Week in AI
Last Week in AI
T
The Blog of Author Tim Ferriss
腾讯CDC
Hugging Face - Blog
Hugging Face - Blog
T
Tailwind CSS Blog
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
I
InfoQ
月光博客
月光博客
博客园_首页
Vercel News
Vercel News
P
Proofpoint News Feed
GbyAI
GbyAI
Y
Y Combinator Blog

Show HN

Show HN: AI agents for UK GDAD PCF roles and their skills The Two Pillars: Mixer Mode and Meta-Software in the Reorganization of Software Work After AI GitHub - JaiCode08/teleport-env What 1,000+ Harness Experiments Taught Me About Self-Improving Agents Show HN: Liiists, a Markdown-first, iOS and CLI list app SwiperTab – Get this Extension for 🦊 Firefox (en-US) GitHub - kouhxp/fftext: Summarize, explain, fact-check, or translate any text, URL, or file. No GPU. No cloud. One command GitHub - sweetpad-dev/sweetpad: Develop Swift/iOS projects using VSCode GitHub - dogmaticdev/IRON: IRON a.k.a. Intermediate Representation Object Notation is a Interpreter/Database that is used to create Programming Languages. GitHub - sjhalani7/vaen: Package your AI coding harness into a portable .agent file, and share it across repos, teams, & the community without ever having to copy-paste instructions, skills, MCP config, or secrets. Show HN: Gandalf the Grader Show HN: Citadeld – replay any CI failure locally from a single file GitHub - tdortman/cuSBF: High-Performance GPU Super Bloom Filter coral-ai/claude-code-token-xray at main · Coral-Bricks-AI/coral-ai GitHub - ulyssestenn/funes: Funes is a Git-based framework for LLM-managed knowledge work: an AI Librarian ingests raw sources, builds an interlinked Markdown knowledge base, and uses it to produce cited reports, analyses, and other outputs. GitHub - ThatXliner/gah: Git Add Hunk, built for agents to use GitHub - harmont-dev/harmont-cli: Command-line client for the Harmont CI platform GitHub - brooksmcmillin/mcp-authflow: OAuth 2.0 Authorization Server framework for MCP servers GitHub - javaid-codes/audit-supply-chain-agents GitHub - amorey/gochan: A small library of common channel architectures for Go, inspired by Rust GitHub - arifozgun/OpenGem: Free, Open-Source AI API Gateway with Gemini, OpenAI & Anthropic Compatibility in 1 file GitHub - Pranesh950/BioPetals: 🌸 Run BIOxAI models at home, BitTorrent-style. Fine-tuning and inference up to 10x faster than offloading GitHub - cnguyen14/bounty-doctor: Diagnose a GitHub bounty issue before you waste hours: detects honeypot scam repos, AI-bot attempt swarms, and stale contests. Show HN: CoreMCP – MCP Server for On-Prem DBs Show HN: KittyHTML – Render HTML/CSS as an inline image in your terminal GitHub - bingud/filemat: Web-based file manager Show HN: TruthLens – Free multi-signal deepfake image detector GitHub - apexlocal-jz/claude-usage-tray: Windows system-tray app showing your Claude Code rate-limit usage at a glance. Zero deps, ~300 lines of PowerShell. Cross-IDE (works regardless of VS Code, Cursor, plain terminal). Release v0.1.2.1 · kouhxp/yapsnap GitHub - noopolis/moltnet: Self-hostable chat network for AI agents. Pre-built bridges for Claude Code, Codex, and the Claws. Rooms, DMs, history. No Slack bots, no Matrix, no glue code.
Llmrender
franciscop · 2026-06-13 · via Show HN

A fully featured Markdown renderer for React. From README files to streaming LLM output, one component renders it all:

  • LaTeX rendering for math
  • 30+ languages highlighted
  • Under 12kb, 0 dependencies
  • GitHub Flavored Markdown
  • Streaming-safe rendering
  • 500+ tests, 99.9% coverage
npm install llmrender
# Release 1.0 is available

Now **faster** and ~~heavier~~ lighter. Even $E = mc^2$ renders inline.

$$
\int_0^\infty e^{-x^2} dx = \frac{\sqrt{\pi}}{2}
$$

You also have **30+ languages** supported in the default Syntax Highlighting:

```jsx
import Markdown from "llmrender";
const App = ({ text }) => <Markdown>{text}</Markdown>;
```

your markdown what your users see

Try it live

Edit the Markdown on the left, or press ▶ stream to watch it render token by token, exactly the way your LLM output arrives.

Syntax highlighting

30+ languages, no highlighter to install

Fenced code blocks come out colored without adding highlight.js or Prism to your bundle. JavaScript, TypeScript, Python, Rust, Go, SQL, CSS, HTML, shell, diff and many more are recognized out of the box.

  • Four ready-made themes: light, dark, adaptive and high-contrast
  • Unknown languages degrade gracefully to plain code blocks
  • Prefer your own stack? Pass any function to the highlight prop and plug in Prism.js in three lines
// Built in, just write Markdown
<Markdown>{text}</Markdown>

// …or bring your own highlighter
<Markdown
  highlight={(code, lang) => (
    <SyntaxHighlighter language={lang}>
      {code}
    </SyntaxHighlighter>
  )}
>

LaTeX math

LaTeX in, native MathML out

LLMs love emitting LaTeX. LLMRender parses it and renders browser-native MathML: fractions, roots, matrices, Greek letters, sums, integrals and accents.

  • Inline $…$ and display $$…$$ syntax
  • Crisp at any zoom level and accessible to screen readers
  • Want KaTeX anyway? Pass it through the math prop and keep everything else
Inline $e^{i\pi} + 1 = 0$ math.

$$
\sum_{n=1}^{\infty} \frac{1}{n^2} = \frac{\pi^2}{6}
$$

Inline eiπ+1=0 math.

∑ n=1 ∞ 1 n2 = π2 6

GitHub Flavored Markdown

The Markdown everyone actually writes

From READMEs to chat replies, real-world Markdown is GitHub flavored, and LLMRender renders all of it: tables with column alignment, task lists with checkboxes, strikethrough, autolinks, and the [!NOTE]/[!TIP]/[!WARNING] callouts that make documents scannable.

  • Headings get ids and anchor links for deep-linking
  • Nested lists, blockquotes and code inside blockquotes
  • Plus extras like ruby annotations for East-Asian text
> [!WARNING]
> Callouts render with icons and colors.

| Model | Score |
|:------|------:|
| A     |  98.2 |

- [x] Tables, aligned
- [x] Task lists
- [x] ~~Missing features~~

Streaming

Made for tokens arriving mid-sentence

Streaming output means the renderer sees half-finished Markdown hundreds of times per response. LLMRender is designed for that: just re-render with the text you have so far, with no buffering, no flicker, no crashes.

  • Unclosed code fences render as code while they stream
  • Unclosed $$ math blocks render as math
  • Fast enough to re-parse the whole message on every chunk
const [text, setText] = useState("");

for await (const chunk of stream) {
  setText((t) => t + chunk);
}

// Re-render on every chunk: unclosed
// ``` fences and $$ blocks mid-stream
// render gracefully, never break
return <Markdown>{text}</Markdown>;

Security

Safe with untrusted content by default

Whether it comes from users, files or models, Markdown can carry malicious payloads, so LLMRender is safe by default: javascript: and data: URLs are neutralized, raw HTML is ignored unless you opt in, and even then it goes through a strict tag and attribute allowlist.

  • No dangerouslySetInnerHTML anywhere, ever
  • rawHtml blocks scripts, event handlers, iframes and styles even when enabled
  • target="_blank" links get rel="noopener noreferrer" against tabnabbing
// Safe by default: HTML ignored,
// dangerous URLs neutralized
<Markdown>{untrusted}</Markdown>

// Opt in to a safe HTML allowlist
<Markdown rawHtml>{untrusted}</Markdown>

// …or define exactly what's allowed
<Markdown rawHtml={{ b: [], a: ["href"] }}>
  {untrusted}
</Markdown>

Styling

It's just a <div>, style it your way

The output is a plain <div> with semantic HTML inside, so Tailwind Typography, Styled Components, CSS Modules or plain stylesheets all work with zero adapters.

  • Four importable themes: default, dark, adaptive (follows prefers-color-scheme) and contrast (WCAG AAA)
  • Theme colors exposed as --llmrender-* CSS variables
  • Every <div> attribute passes through: className, style, data-*
// Pick a theme…
import "llmrender/themes/adaptive.css";

// …then style it like any other div
<Markdown
  className="prose dark:prose-invert"
  id="answer"
  data-testid="chat-message"
>
  {text}
</Markdown>

Bundle size

A fraction of the usual stack

Markdown + math + highlighting + sanitizing, measured as real bundle overhead in identical Vite builds (methodology):

Package Base Math Highlight Sanitize Full size (gzip)
LLMRender 9 KB built-in built-in built-in 12 KB
react-markdown 33.3 KB +74.6 KB +508 KB built-in 340 KB
marked 12.1 KB +74.6 KB +298 KB +8.7 KB 403 KB
markdown-it 43.3 KB +74.6 KB +298 KB +8.7 KB 436 KB

Install it now

npm install llmrender