markstream-vue2
它能做什么
这个工具可以帮你把 “markstream-vue2” 组件集成到使用 Vue 2 的项目中。它会确保组件与具体的 Vue 2 版本正常配合,并处理好其中的技术细节,让你省心。
适用场景
- ✓当你使用 Vue 2.6 或 2.7,并且需要一个组件来显示带格式的文本(比如 Markdown)时。
- ✓当你希望文字像聊天一样逐步出现在屏幕上时。
- ✓如果你需要确保与较旧的 Vue 2 版本兼容时。
技能链接
https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/markstream-vue2/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“我要怎样在 Vue 2 项目中设置 markstream-vue2?”
每周 5 个新技能,1 分钟读完。
工作原理
工具会检查你的 Vue 2 版本,并添加必要的依赖。它会配置组件来显示文本,并提供打字效果或逐步出现的动画选项。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
Markstream Vue 2
Overview
Handle Vue 2.6/2.7 compatibility decisions that the generic installer cannot resolve safely.
When to Use
Use for Vue 2 integration when no bundler-specific edge case dominates. Use markstream-vue2-cli for Vue CLI/Webpack 4 and markstream-vue2-vite for Vite worker imports.
Workflow
Inspect the existing package manager, installed package version and project conventions. A requested scoped integration already authorizes routine source/dependency edits; seek approval only for a material scope expansion or unresolved beta/alpha adoption decision.
- Confirm Vue 2.6 or 2.7 and install
markstream-vue2. - Add
@vue/composition-apionly for Vue 2.6 code that uses Composition API patterns; Vue 2.7 has built-in support. - Import
markstream-vue2/index.cssafter resets. - Start with
<MarkdownRender :content="markdown" />and smooth streamingauto. - For live chat disable fade and opt into the cursor; on completion set
final, disable pacing/cursor, and enable fade only if desired. - Use
nodesonly when another layer owns parsing. Use scoped mappings for overrides. - Keep HTML safe and Mermaid strict; validate with the smallest build or dev command.
Example
<script>
import MarkdownRender from 'markstream-vue2'
import 'markstream-vue2/index.css'
export default {
components: { MarkdownRender },
props: { content: String, done: Boolean },
}
</script>
<template>
<MarkdownRender
:content="content"
:final="done"
:fade="done"
:typewriter="!done"
/>
</template>
Limitations
- Vue 2.6 and 2.7 have different Composition API requirements.
- Legacy bundlers require the dedicated specializations.
- Optional modern peers may not support every Vue 2 toolchain.
Security & Safety Notes
Review dependency and compatibility changes. Do not relax rendering safety for untrusted content.
Verify props, export paths and peer ranges against the installed package, not a mutable upstream main. Test partial and completed streams, malformed/untrusted Markdown, links and image URLs, cancellation and reduced motion. Safe HTML and strict diagrams reduce exposure but do not alone enforce URL/network privacy or application component permissions.
Vue 2 is end-of-life; preserve a requested legacy integration and document its maintenance/support decision rather than silently upgrading the whole application. Prefer reviewed locally bundled workers over mutable CDN code where feasible.
常见问题
什么是 “Composition API”?
它是 Vue.js 中一种更现代的代码组织方式。在 Vue 2.6 中,你可能需要额外安装一个包才能使用;Vue 2.7 则内置了支持。
“streaming state” 是什么意思?
意思是文本可以一小块一小块地显示,就像正在被打字或实时加载一样,而不是一次全部出现。
这个工具能用于任何 Vue 版本吗?
不能。这个工具专门针对 Vue 2.6 和 2.7。对于其他版本或构建工具(比如 Vite),这个工具有对应的其他版本。
详情
作者的原始描述
Integrate markstream-vue2 into Vue 2.6 or 2.7 with correct Composition API decisions, CSS, streaming state, optional peers, and scoped overrides.
热度
- GitHub 星标
- 48k
- 排名
- #5177
- 许可证
- MIT
- 更新时间
- 2026/10/15
评论
- …
同一仓库的更多技能
00-andruia-consultant
48k帮你的智能体启动或改进 AI 项目。它可以分析代码、推荐工具,并用西班牙语制定行动计划。
007
48k让你的智能体执行安全审计和威胁建模。它有助于保护项目免受攻击和漏洞的威胁。
10-andruia-skill-smith
48k帮你的智能体创建或改进 AI 工具。它可以定义工具的工作方式、编写文档,并验证其结构。
20-andruia-niche-intelligence
48k让你的智能体创建某个特定行业的摘要。它有助于借助可靠的信息来源,了解项目的背景、规则、使用模式和风险。