Skip to content

feat: rename components to Markdown and MarkdownParsed - #313

Merged
atinux merged 6 commits into
mainfrom
feat/rename-markdown-components
Jul 30, 2026
Merged

feat: rename components to Markdown and MarkdownParsed#313
atinux merged 6 commits into
mainfrom
feat/rename-markdown-components

Conversation

@atinux

@atinux atinux commented Jul 30, 2026

Copy link
Copy Markdown
Contributor

🔗 Linked issue

N/A

❓ Type of change

  • 📖 Documentation (updates to the documentation or readme)
  • 🐞 Bug fix (a non-breaking change that fixes an issue)
  • 👌 Enhancement (improving an existing functionality like performance)
  • ✨ New feature (a non-breaking change that adds functionality)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

📚 Description

Renames Comark's public components across every framework package so component names describe what they render, not the library. The Comark brand stays for the project, packages, and parser APIs.

Renames

Old New
Comark Markdown
ComarkRenderer MarkdownParsed
ComarkClient / ComarkLive (React) MarkdownClient / MarkdownLive
ComarkAsync / ComarkNode (Svelte) MarkdownAsync / MarkdownNode
ComarkComponent / ComarkRendererComponent / ComarkNodeComponent (Angular) Markdown / MarkdownParsed / MarkdownNode
Angular selectors comark / comark-renderer / comark-node comark-markdown / comark-markdown-parsed / comark-markdown-node
defineComarkComponent / defineComarkRendererComponent defineMarkdownComponent / defineMarkdownParsedComponent
ComarkProps / ComarkRendererProps / … MarkdownProps / MarkdownParsedProps / …
props markdown / tree value

Target usage:

<Markdown :value="source" :components="{ Alert }" />
<MarkdownParsed :value="document" :components="{ Alert }" />

Backward compatibility (non-breaking)

  • All old component names, types, factories, and the markdown/tree props keep working as deprecated aliases (@deprecated JSDoc pointing to the new name).
  • Old names/props log a one-time console warning in development (silent in production), via a small internal/deprecation.ts helper per package.
  • Svelte's public ./components/* subpaths are preserved: old .svelte files remain as thin deprecated wrappers.
  • The Nuxt module auto-registers both the new (Markdown, MarkdownParsed) and old names.

Scope

  • Packages: @comark/vue, @comark/react, @comark/svelte, @comark/angular, @comark/nuxt (+ JSDoc-only touches in comark core)
  • All examples (examples/1.frameworks, 2.vite, 3.plugins, 4.ai) and benchmarks migrated to the new names
  • All docs pages, docs app, and agent skills updated; new migration note at docs/content/7.kb/5.renamed-components.md (no page slugs changed, so no redirects needed)
  • Root README.md, package READMEs, and AGENTS.md updated
  • New alias regression tests: packages/comark-vue/test/deprecated-aliases.test.ts, packages/comark-react/test/deprecated-aliases.test.tsx

Verification

  • pnpm build ✅ (all packages)
  • Package tests ✅ — Vue 74, React 53, Svelte 105 (incl. browser), Angular 45, HTML 44, ANSI 51; the 2 core wrapped-pre-highlighted.md failures are pre-existing on main
  • pnpm typecheck — remaining 4 errors are identical on main (pre-existing, unrelated)
  • pnpm lint
  • rg '<Comark|ComarkRenderer' — remaining hits are only deprecated alias definitions, alias tests, the migration note, and changelog history

📝 Checklist

  • I have linked an issue or discussion.
  • I have run pnpm verify and it passes.
  • I have updated the documentation accordingly.

Component names now describe what they render instead of carrying the
library brand:

- `Comark` -> `Markdown` (raw markdown source in, parsed and rendered)
- `ComarkRenderer` -> `MarkdownParsed` (renders an already-parsed document)
- `ComarkClient`/`ComarkLive` (React) -> `MarkdownClient`/`MarkdownLive`
- `ComarkAsync`/`ComarkNode` (Svelte) -> `MarkdownAsync`/`MarkdownNode`
- Angular classes -> `Markdown`/`MarkdownParsed`/`MarkdownNode` with
  prefixed selectors (`comark-markdown`, `comark-markdown-parsed`,
  `comark-markdown-node`)
- `defineComarkComponent` -> `defineMarkdownComponent`,
  `defineComarkRendererComponent` -> `defineMarkdownParsedComponent`
- `markdown`/`tree` props -> `value`

All old names and props keep working as deprecated aliases with a
one-time dev-only console warning. The Comark brand, package names, and
parser APIs are unchanged. Examples, docs, skills, and READMEs migrated;
migration note added at docs/content/7.kb/5.renamed-components.md.
@vercel

vercel Bot commented Jul 30, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
comark Ready Ready Preview Jul 30, 2026 2:52pm
comark-json-render Ready Ready Preview Jul 30, 2026 2:52pm
comark-nextjs Ready Ready Preview Jul 30, 2026 2:52pm
comark-nuxt Ready Ready Preview Jul 30, 2026 2:52pm
comark-svelte Ready Ready Preview Jul 30, 2026 2:52pm
comark-sveltekit Ready Ready Preview Jul 30, 2026 2:52pm
comark-twoslash Ready Ready Preview Jul 30, 2026 2:52pm
comark-vue Ready Ready Preview Jul 30, 2026 2:52pm

@pkg-pr-new

pkg-pr-new Bot commented Jul 30, 2026

Copy link
Copy Markdown

Open in StackBlitz

comark

npm i https://pkg.pr.new/comark@313

@comark/angular

npm i https://pkg.pr.new/@comark/angular@313

@comark/ansi

npm i https://pkg.pr.new/@comark/ansi@313

@comark/html

npm i https://pkg.pr.new/@comark/html@313

@comark/nuxt

npm i https://pkg.pr.new/@comark/nuxt@313

@comark/react

npm i https://pkg.pr.new/@comark/react@313

@comark/svelte

npm i https://pkg.pr.new/@comark/svelte@313

@comark/vue

npm i https://pkg.pr.new/@comark/vue@313

commit: b398ec0

@atinux
atinux merged commit e6a6b60 into main Jul 30, 2026
12 checks passed
@atinux
atinux deleted the feat/rename-markdown-components branch July 30, 2026 16:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants