You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by ju...@apache.org on 2021/10/21 16:21:59 UTC
[apisix-website] 01/01: feat: support jsDelivr CDN to speedup
static files
This is an automated email from the ASF dual-hosted git repository.
juzhiyuan pushed a commit to branch juzhiyuan-patch-1
in repository https://gitbox.apache.org/repos/asf/apisix-website.git
commit 25dba191925a456dbd7b32aa51ecf1698fc1c1a8
Author: ηθ΄θΏ <ju...@apache.org>
AuthorDate: Fri Oct 22 00:21:51 2021 +0800
feat: support jsDelivr CDN to speedup static files
---
scripts/sync-docs.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/scripts/sync-docs.js b/scripts/sync-docs.js
index d9ef271..2943f90 100644
--- a/scripts/sync-docs.js
+++ b/scripts/sync-docs.js
@@ -296,7 +296,7 @@ const replaceMDElements = (project, path, branch = "master") => {
from: /(\.\.\/)+assets\/images\/[-A-Za-z0-9+&@#/%?=~_|!:,.;]+[-A-Za-z0-9+&@#/%=~_|]/g,
to: (match) => {
const imgPath = match.replace(/\(|\)|\.\.\/*/g, "");
- const newUrl = `https://raw.githubusercontent.com/apache/${project}/${branch}/docs/${imgPath}`;
+ const newUrl = `https://cdn.jsdelivr.net/gh/apache/${project}@${branch}/docs/${imgPath}`;
//console.log(`${project}: ${match} π ${newUrl}`);
return newUrl;
},