从 VuePress 迁移
Markdown
Images
与 VuePress 不同,当你使用静态图片时,VitePress 会自动根据config中base的配置项来处理。
因此,现在你可以不用img标签来渲染图片。
diff
- <img :src="$withBase('/foo.png')" alt="foo">
+ WARNING
对于动态图像,你仍然需要withBase,如Base URL指南中所示。
Use <img.*withBase\('(.*)'\).*alt="([^"]*)".*> regex to find and replace it with  to replace all the images with  syntax.
更多内容请关注...