Repository navigation
[Draft] feat(component-library): add MtMarkdown - #1398
Closed
Arnold Stoba (arnoldstoba) wants to merge 4 commits into
Closed
Arnold Stoba (arnoldstoba) wants to merge 4 commits into
Arnold Stoba (arnoldstoba) wants to merge 4 commits into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Arnold Stoba (arnoldstoba)
force-pushed
the
feat/mt-markdown
branch
from
October 5, 2026 10:27
4932d83 to
039f3f7
Compare
Arnold Stoba (arnoldstoba)
force-pushed
the
feat/mt-markdown
branch
from
October 6, 2026 14:37
039f3f7 to
9035d94
Compare
This branch was successfully deployed
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
What?
Adds the experimental
MtMarkdown, which renders Markdown such as an AI answer, also while it is still streaming. It is a configured wrapper around Comark's<Markdown>with Meteor's typography.http,https,mailtoandtel, and images with a full address only load fromallowedImagePrefixes.Why?
AI answers arrive as Markdown, token by token:
An answer such as
Two products are **low on stock**:would show raw**while it streams. Converting it to HTML forv-htmlwould run untrusted model output as HTML, and a model's answer can be influenced by the data it reads.How?
**bold.prewith Meteor's code block, which adds the copy button;ProsePdon't change the content.MtMarkdown: its code is in a chunk that onlyMtMarkdownand the rootindex.jsimport, and importing other components leaves it out. A new size-limit entry tracksMtMarkdownon its own.@comark/vue(MIT). The full bundle budget grows by about 54 kB.Testing?
Specs for our configuration (tables, task lists, raw HTML, unsafe links, images, copying, streaming) and SSR with hydration. Unit tests, types, build, size-limit, the docs build and the Nuxt example build pass.
Anything Else?
mt-reasoningrenders its text withMtMarkdown, andmt-toolreuses the code block. Itsmt-toolneeds to pass code to the code block as slot content after rebasing.