We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
近日所在网络环境无法访问 unpkg.com,使用 cdn 属性指定自建 CDN 后,仍有少量资源通过 unpkg.com 访问,包括主题 CSS(例如 /dist/css/content-theme/light.css)与 Emoji 图片(例如 /dist/images/emoji/hacpai.png)。要使这些资源也使用自建 CDN,需要额外设置其他选项,较为麻烦,编辑器与预览选项还有一些差异。
cdn
只要设置好 cdn 这一个属性,所有资源都能通过自建 CDN 访问。
完全使用自建 CDN 所需的完整选项实例:
const CDN = '/third_party/vditor' // 编辑器选项 new Vditor('vditor', { cdn: CDN, preview: { theme: { current: 'light', path: `${CDN}/dist/css/content-theme`, }, }, hint: { emojiPath: `${CDN}/dist/images/emoji`, }, }) // 预览选项 Vditor.preview(el, content, { cdn: CDN, mode: 'light', theme: { current: 'light', path: `${CDN}/dist/css/content-theme`, }, emojiPath: `${CDN}/dist/images/emoji`, })
The text was updated successfully, but these errors were encountered:
🎨 fix #1522
a42598c
请问下,改进后的版本是不是只需要配置一个cdn属性就行了
Sorry, something went wrong.
嗯嗯
按照配置走的自建cnd,但是报401是什么问题
看上去是服务器没授权。
Vanessa219
No branches or pull requests
描述问题
近日所在网络环境无法访问 unpkg.com,使用
cdn
属性指定自建 CDN 后,仍有少量资源通过 unpkg.com 访问,包括主题 CSS(例如 /dist/css/content-theme/light.css)与 Emoji 图片(例如 /dist/images/emoji/hacpai.png)。要使这些资源也使用自建 CDN,需要额外设置其他选项,较为麻烦,编辑器与预览选项还有一些差异。期待的结果
只要设置好
cdn
这一个属性,所有资源都能通过自建 CDN 访问。版本信息
其他信息
完全使用自建 CDN 所需的完整选项实例:
The text was updated successfully, but these errors were encountered: