Repository navigation
feat(md): Zig markdown parser with Bun.markdown API #26440
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 6 commits
Commits
Show all changes
56 commits
Select commit
Hold shift + click to select a range
11f1984
feat(md): add Zig markdown parser with .md loader and Bun.Markdown API
Jarred-Sumner 437cd0c
[autofix.ci] apply automated fixes
autofix-ci[bot] f52dab0
feat(md): split parser, add renderer abstraction, and Bun.Markdown.re…
Jarred-Sumner d08bb33
[autofix.ci] apply automated fixes
autofix-ci[bot] 41020e9
feat(md): implement GFM disallowed raw HTML tag filter
Jarred-Sumner 598c141
Merge branch 'main' into jarred/mdx
Jarred-Sumner 8af45e1
refactor(md): rename API to Bun.markdown.html/render, add custom rend…
Jarred-Sumner 343a83e
fix(md): GFM compatibility fixes, ban-words compliance, and type safety
Jarred-Sumner 1d5d72f
feat(md): add TypeScript types and documentation for Bun.markdown API
Jarred-Sumner 71819e2
[autofix.ci] apply automated fixes
autofix-ci[bot] 96e8d07
refactor(md): idiomatic Zig cleanup and deduplication
Jarred-Sumner 531dbef
Fix
Jarred-Sumner b0518cf
[autofix.ci] apply automated fixes
autofix-ci[bot] 9b4e95d
feat(md): add heading_ids and autolink_headings renderer options
Jarred-Sumner 47487bb
[autofix.ci] apply automated fixes
autofix-ci[bot] 9500d75
feat(md): use camelCase for JavaScript API options
Jarred-Sumner 4f9a815
fix(md): use bun.StringHashMapUnmanaged instead of std
Jarred-Sumner b2d4b76
fix(md): address code review feedback
Jarred-Sumner 9d6f52e
docs(md): update options to camelCase and add headingIds/autolinkHead…
Jarred-Sumner aec9a1f
refactor(md): deduplicate entity/slug code between renderers
Jarred-Sumner bdd71d2
fix(md): assorted cleanups across renderer and types
Jarred-Sumner 20f6901
fix(md): propagate errors through VTable and add stack overflow checks
Jarred-Sumner ae1a940
[autofix.ci] apply automated fixes
autofix-ci[bot] ebc2eb0
feat(md): add Bun.markdown.react() and Bun.markdown.render() APIs
Jarred-Sumner fe3e542
docs(md): update TypeScript types for render/react APIs
Jarred-Sumner c90018b
feat(md): react() returns a Fragment element, update types and docs
Jarred-Sumner 76fabbc
feat(md): restore callback-based render(), default reactVersion to 19
Jarred-Sumner cfeb087
feat(md): add specific typed props for render callbacks and fuzzer tests
Jarred-Sumner fb7b08f
[autofix.ci] apply automated fixes
autofix-ci[bot] 1c58726
refactor(md): split tests, bitset fast-path, HeadingIdTracker, metada…
Jarred-Sumner 4725921
[autofix.ci] apply automated fixes
autofix-ci[bot] 08dc571
fix(md): slug_counts memory safety, forward RenderOptions, move imports
Jarred-Sumner 403be5f
Update WebKit (#26449)
dylan-conway 3d1bec0
fix(napi): fix use-after-free in property names and external buffer l…
dylan-conway 3dec010
fix(build-jsc): enable REMOTE_INSPECTOR for macOS release builds (#26…
sosukesuzuki 244f447
fix(lint): remove unused variables in readline and ConsoleObject (#26…
sosukesuzuki 2738c5b
docs(test): update static-initializers.test.ts comments to reflect mi…
robobun 354aecf
Fix hash map use-after-free in macro (#26451)
kirillmarkelov 03e3228
test: add JSC JIT stress tests from WebKit (#26380)
sosukesuzuki a3ffcd8
Add benchmark for `[...set]` (#26452)
sosukesuzuki 26b5cae
feat: add native JSON5 parser (Bun.JSON5) (#26439)
dylan-conway 5ca44d7
fix(http2): prevent extra empty DATA frame on write()+end() pattern (…
robobun 6ae0390
feat(md): rename to unstable_markdown, restructure API args
Jarred-Sumner 678281e
docs(md): add unstable API note, remove individual autolink/heading o…
Jarred-Sumner c8b67b5
merge: resolve conflicts with main (md loader entries)
Jarred-Sumner 899d3d5
[autofix.ci] apply automated fixes
autofix-ci[bot] 0578daf
rename Bun.unstable_markdown to Bun.markdown
dylan-conway d5cb86f
[autofix.ci] apply automated fixes
autofix-ci[bot] 87ac50b
use arena
dylan-conway 82cf6b3
add Parser.Error
dylan-conway 36c428d
[autofix.ci] apply automated fixes
autofix-ci[bot] e2efc47
JSX.Element
dylan-conway e3810b3
Merge branch 'main' into jarred/mdx
dylan-conway ae37f72
Merge branch 'main' into jarred/mdx
dylan-conway c001356
introduce a jsx.d.ts which reaches for React's types when available, …
alii 7bd8073
bump .stdDir() ban limit to 42
dylan-conway File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
🏁 Script executed:
Repository: oven-sh/bun
Length of output: 11038
🏁 Script executed:
Repository: oven-sh/bun
Length of output: 2404
🏁 Script executed:
Repository: oven-sh/bun
Length of output: 1783
🏁 Script executed:
Repository: oven-sh/bun
Length of output: 50367
🏁 Script executed:
Repository: oven-sh/bun
Length of output: 773
Add missing loader type constants to C/C++ bindings and resolve numeric conflicts.
The Zig
Loaderenum and C/C++BunLoaderTypedefinitions are out of sync despite the explicit requirement inheaders-handwritten.h. The C/C++ headers are missing constants for values 12–18 (base64,dataurl,text,bunsh,sqlite,sqlite_embedded,html),json5is completely absent, andmdhas conflicting values (21 in Zig vs. 20 in C/C++). Add all missingBunLoaderTypeconstants and ensure numeric values align precisely with the Zig enum.🤖 Prompt for AI Agents