Closed XCLHove closed 6 months ago
ir
代码:
<script setup lang="ts"> import {onMounted, ref} from "vue"; import Vditor from 'vditor' import 'vditor/dist/index.css' const vditor = ref<HTMLDivElement>() onMounted(() => { Vditor.preview(vditor.value, '# title') }) </script> <template> <div class="container"> <div ref="vditor"></div> </div> </template> <style scoped> .container { box-sizing: border-box; padding: 30px 0; } </style>
页面正常渲染
demo 上是正常的,这个错误信息看不出具体的问题。
配置一下cdn就好了:
Vditor.preview(vditor.value, '# title', { cdn: 'https://unpkg.com/vditor@3.10.2' })
依赖包中有对应js为什么还要去cdn拿,不是很能理解
lute 太大了
编辑模式
ir
即时渲染模式描述问题
代码:
期待的结果
页面正常渲染
截屏或录像
版本信息
其他信息