fix(cdn): use fastly CDN temporarily
diff --git a/_jade/components/builder.jade b/_jade/components/builder.jade
index 1ae66c0..794341e 100644
--- a/_jade/components/builder.jade
+++ b/_jade/components/builder.jade
@@ -124,7 +124,7 @@
include ../en/footer
block extra_js
- script(src="https://cdn.jsdelivr.net/npm/compare-versions@3.6.0/index.min.js")
+ script(src="https://fastly.jsdelivr.net/npm/compare-versions@3.6.0/index.min.js")
script.
var $versionsDom = document.querySelector('#versions');
diff --git a/_jade/en/events.jade b/_jade/en/events.jade
index ff117fb..a42a118 100644
--- a/_jade/en/events.jade
+++ b/_jade/en/events.jade
@@ -42,4 +42,4 @@
elements_selector: ".lazy"
};
document.getElementById('nav-contribute').className = 'active';
- script(src='https://cdn.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
+ script(src='https://fastly.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
diff --git a/_jade/en/events/2021-05-13-iscas.jade b/_jade/en/events/2021-05-13-iscas.jade
index 355f185..d70409d 100644
--- a/_jade/en/events/2021-05-13-iscas.jade
+++ b/_jade/en/events/2021-05-13-iscas.jade
@@ -128,4 +128,4 @@
elements_selector: ".lazy"
};
document.getElementById('nav-contribute').className = 'active';
- script(src='https://cdn.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
+ script(src='https://fastly.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
diff --git a/_jade/en/events/2021-07-05-apachecon.jade b/_jade/en/events/2021-07-05-apachecon.jade
index fdb3af9..13e65e9 100644
--- a/_jade/en/events/2021-07-05-apachecon.jade
+++ b/_jade/en/events/2021-07-05-apachecon.jade
@@ -80,4 +80,4 @@
elements_selector: ".lazy"
};
document.getElementById('nav-contribute').className = 'active';
- script(src='https://cdn.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
+ script(src='https://fastly.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
diff --git a/_jade/en/feature.jade b/_jade/en/feature.jade
index 73560c0..fafccc8 100644
--- a/_jade/en/feature.jade
+++ b/_jade/en/feature.jade
@@ -97,6 +97,6 @@
window.lazyLoadOptions = {
elements_selector: 'iframe'
};
- script(src='https://cdn.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
+ script(src='https://fastly.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
script(type='text/javascript').
document.getElementById('nav-doc').className = 'active';
diff --git a/_jade/en/index.jade b/_jade/en/index.jade
index 44e77b7..d98aaf2 100644
--- a/_jade/en/index.jade
+++ b/_jade/en/index.jade
@@ -5,8 +5,8 @@
block extra_head
title Apache ECharts
- script(src="https://cdn.jsdelivr.net/npm/scrollreveal@4.0.7/dist/scrollreveal.min.js")
- script(src="https://cdn.jsdelivr.net/npm/lottie-web@5.7.6/build/player/lottie.min.js")
+ script(src="https://fastly.jsdelivr.net/npm/scrollreveal@4.0.7/dist/scrollreveal.min.js")
+ script(src="https://fastly.jsdelivr.net/npm/lottie-web@5.7.6/build/player/lottie.min.js")
block content
nav(class='navbar navbar-default navbar-fixed-top', role="navigation")
@@ -164,6 +164,6 @@
window.lazyLoadOptions = {
elements_selector: ".lazy"
};
- script(src='https://cdn.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
+ script(src='https://fastly.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
script(src='#{cdnPayRoot}/#{ecWWWLang}/js/index.js?_v_=#{homeVersion}')
//- <script async defer src="https://buttons.github.io/buttons.js"></script>
diff --git a/_jade/zh/events.jade b/_jade/zh/events.jade
index d3f0315..c0734bb 100644
--- a/_jade/zh/events.jade
+++ b/_jade/zh/events.jade
@@ -45,4 +45,4 @@
elements_selector: ".lazy"
};
document.getElementById('nav-contribute').className = 'active';
- script(src='https://cdn.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
+ script(src='https://fastly.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
diff --git a/_jade/zh/events/2021-05-13-iscas.jade b/_jade/zh/events/2021-05-13-iscas.jade
index e92c96f..87f34a8 100644
--- a/_jade/zh/events/2021-05-13-iscas.jade
+++ b/_jade/zh/events/2021-05-13-iscas.jade
@@ -128,4 +128,4 @@
elements_selector: ".lazy"
};
document.getElementById('nav-contribute').className = 'active';
- script(src='https://cdn.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
+ script(src='https://fastly.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
diff --git a/_jade/zh/events/2021-07-05-apachecon.jade b/_jade/zh/events/2021-07-05-apachecon.jade
index 5031ec8..04f0db1 100644
--- a/_jade/zh/events/2021-07-05-apachecon.jade
+++ b/_jade/zh/events/2021-07-05-apachecon.jade
@@ -80,4 +80,4 @@
elements_selector: ".lazy"
};
document.getElementById('nav-contribute').className = 'active';
- script(src='https://cdn.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
+ script(src='https://fastly.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
diff --git a/_jade/zh/feature.jade b/_jade/zh/feature.jade
index 101db89..5573dc2 100644
--- a/_jade/zh/feature.jade
+++ b/_jade/zh/feature.jade
@@ -94,6 +94,6 @@
window.lazyLoadOptions = {
elements_selector: 'iframe'
};
- script(src='https://cdn.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
+ script(src='https://fastly.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
script(type='text/javascript').
document.getElementById('nav-doc').className = 'active';
diff --git a/_jade/zh/index.jade b/_jade/zh/index.jade
index addbfc8..982f638 100644
--- a/_jade/zh/index.jade
+++ b/_jade/zh/index.jade
@@ -4,8 +4,8 @@
block extra_head
title Apache ECharts
- script(src="https://cdn.jsdelivr.net/npm/scrollreveal@4.0.7/dist/scrollreveal.min.js")
- script(src="https://cdn.jsdelivr.net/npm/lottie-web@5.7.6/build/player/lottie.min.js")
+ script(src="https://fastly.jsdelivr.net/npm/scrollreveal@4.0.7/dist/scrollreveal.min.js")
+ script(src="https://fastly.jsdelivr.net/npm/lottie-web@5.7.6/build/player/lottie.min.js")
block content
nav(class='navbar navbar-default navbar-fixed-top', role="navigation")
@@ -159,7 +159,7 @@
include ../components/footer
block extra_js
- script(src='https://cdn.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
+ script(src='https://fastly.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
script(src='#{cdnPayRoot}/#{ecWWWLang}/js/index.js?_v_=#{homeVersion}')
//- <script async defer src="https://buttons.github.io/buttons.js"></script>
@@ -167,4 +167,4 @@
window.lazyLoadOptions = {
elements_selector: ".lazy"
};
- script(src='https://cdn.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
+ script(src='https://fastly.jsdelivr.net/npm/vanilla-lazyload@12.0.0/dist/lazyload.min.js')
diff --git a/builder/build.js b/builder/build.js
index f31a1be..9050e40 100644
--- a/builder/build.js
+++ b/builder/build.js
@@ -15,7 +15,7 @@
var version = BUILD_CONFIG.version + '';
var isVersion5 = version.startsWith('5');
- var jsDelivrBase = 'https://cdn.jsdelivr.net/npm';
+ var jsDelivrBase = 'https://fastly.jsdelivr.net/npm';
var urlArgs = '__v__=' + (+new Date());
diff --git a/config/common.js b/config/common.js
index 3e96a83..abae75f 100644
--- a/config/common.js
+++ b/config/common.js
@@ -1,29 +1,29 @@
module.exports = {
cdnThirdParty: {
- jquery: 'https://cdn.jsdelivr.net/npm/jquery@2.2.4/dist/jquery.min.js',
- jquery_1_11_3: 'https://cdn.jsdelivr.net/npm/jquery@1.11.3/dist/jquery.min.js',
- bootstrapCSS: 'https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css',
- bootstrapJS: 'https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/js/bootstrap.min.js',
- lodash: 'https://cdn.jsdelivr.net/npm/lodash@3.10.1/index.min.js',
- perfectScrollbarJS: 'https://cdn.jsdelivr.net/npm/perfect-scrollbar@0.6.8/dist/js/min/perfect-scrollbar.min.js',
- perfectScrollbarCSS: 'https://cdn.jsdelivr.net/npm/perfect-scrollbar@0.6.8/dist/css/perfect-scrollbar.min.css',
- paceProgressBarJS: 'https://cdn.jsdelivr.net/npm/pace-progressbar@1.0.2/pace.min.js',
- sweetalertJS: 'https://cdn.jsdelivr.net/npm/sweetalert@2.1.2/dist/sweetalert.min.js',
- echartsMinJS_4_8_0: 'https://cdn.jsdelivr.net/npm/echarts@4.8.0/dist/echarts.min.js',
- prettifyJS: 'https://cdn.jsdelivr.net/npm/code-prettify@0.1.0/src/prettify.min.js',
+ jquery: 'https://fastly.jsdelivr.net/npm/jquery@2.2.4/dist/jquery.min.js',
+ jquery_1_11_3: 'https://fastly.jsdelivr.net/npm/jquery@1.11.3/dist/jquery.min.js',
+ bootstrapCSS: 'https://fastly.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css',
+ bootstrapJS: 'https://fastly.jsdelivr.net/npm/bootstrap@3.3.7/dist/js/bootstrap.min.js',
+ lodash: 'https://fastly.jsdelivr.net/npm/lodash@3.10.1/index.min.js',
+ perfectScrollbarJS: 'https://fastly.jsdelivr.net/npm/perfect-scrollbar@0.6.8/dist/js/min/perfect-scrollbar.min.js',
+ perfectScrollbarCSS: 'https://fastly.jsdelivr.net/npm/perfect-scrollbar@0.6.8/dist/css/perfect-scrollbar.min.css',
+ paceProgressBarJS: 'https://fastly.jsdelivr.net/npm/pace-progressbar@1.0.2/pace.min.js',
+ sweetalertJS: 'https://fastly.jsdelivr.net/npm/sweetalert@2.1.2/dist/sweetalert.min.js',
+ echartsMinJS_4_8_0: 'https://fastly.jsdelivr.net/npm/echarts@4.8.0/dist/echarts.min.js',
+ prettifyJS: 'https://fastly.jsdelivr.net/npm/code-prettify@0.1.0/src/prettify.min.js',
// Can not find good prettify css in jsdelivr.
- // prettifyCSS: 'https://cdn.jsdelivr.net/npm/code-prettify@0.1.0/styles/doxy.css',
- prettifyCSSHandlerJS: 'https://cdn.jsdelivr.net/npm/code-prettify@0.1.0/src/lang-css.js',
- jqueryLazyloadJS: 'https://cdn.jsdelivr.net/npm/jquery-lazyload@1.9.7/jquery.lazyload.min.js',
+ // prettifyCSS: 'https://fastly.jsdelivr.net/npm/code-prettify@0.1.0/styles/doxy.css',
+ prettifyCSSHandlerJS: 'https://fastly.jsdelivr.net/npm/code-prettify@0.1.0/src/lang-css.js',
+ jqueryLazyloadJS: 'https://fastly.jsdelivr.net/npm/jquery-lazyload@1.9.7/jquery.lazyload.min.js',
// CDN for doc
- vueJS: 'https://cdn.jsdelivr.net/npm/vue@2.6.11/dist/vue.min.js',
- elementUIJS: 'https://cdn.jsdelivr.net/npm/element-ui@2.13.2/lib/index.js',
- elementUICSS: 'https://cdn.jsdelivr.net/npm/element-ui@2.13.2/lib/theme-chalk/index.css',
- codeMirrorJS: 'https://cdn.jsdelivr.net/npm/codemirror@5.56.0/lib/codemirror.min.js',
- codeMirrorJSModeJS: 'https://cdn.jsdelivr.net/npm/codemirror@5.56.0/mode/javascript/javascript.js',
- beautifierJS: 'https://cdn.jsdelivr.net/npm/js-beautify@1.11.0/js/lib/beautifier.min.js',
+ vueJS: 'https://fastly.jsdelivr.net/npm/vue@2.6.11/dist/vue.min.js',
+ elementUIJS: 'https://fastly.jsdelivr.net/npm/element-ui@2.13.2/lib/index.js',
+ elementUICSS: 'https://fastly.jsdelivr.net/npm/element-ui@2.13.2/lib/theme-chalk/index.css',
+ codeMirrorJS: 'https://fastly.jsdelivr.net/npm/codemirror@5.56.0/lib/codemirror.min.js',
+ codeMirrorJSModeJS: 'https://fastly.jsdelivr.net/npm/codemirror@5.56.0/mode/javascript/javascript.js',
+ beautifierJS: 'https://fastly.jsdelivr.net/npm/js-beautify@1.11.0/js/lib/beautifier.min.js',
},
// Source folder of echarts
diff --git a/config/env.asf.js b/config/env.asf.js
index 04f7081..65976c6 100644
--- a/config/env.asf.js
+++ b/config/env.asf.js
@@ -6,13 +6,13 @@
config.cdnPayRootMap = {
// Expensive!!! use it carefully.
// zh: 'https://echarts-www.cdn.bcebos.com', // origin: 'https://echarts-www.bj.bcebos.com'
- zh: 'https://cdn.jsdelivr.net/gh/apache/echarts-website@asf-site',
+ zh: 'https://fastly.jsdelivr.net/gh/apache/echarts-website@asf-site',
en: 'https://echarts.apache.org'
};
config.cdnFreeRootMap = {
// 'echarts.cdn.apache.org' have been configured for zh (?)
// zh: 'https://echarts.cdn.apache.org',
- zh: 'https://cdn.jsdelivr.net/gh/apache/echarts-website@asf-site',
+ zh: 'https://fastly.jsdelivr.net/gh/apache/echarts-website@asf-site',
en: 'https://echarts.apache.org'
};
config.galleryPath = 'https://echarts.apache.org/examples/';
diff --git a/js/index.js b/js/index.js
index 366844e..a18b7b9 100644
--- a/js/index.js
+++ b/js/index.js
@@ -123,7 +123,7 @@
function loadLandingAnimationScripts() {
return new Promise((resolve) => {
// var landingAnimationURL = 'http://localhost/echarts-www-landing-animation/'
- var landingAnimationURL = 'https://cdn.jsdelivr.net/npm/echarts-www-landing-animation/';
+ var landingAnimationURL = 'https://fastly.jsdelivr.net/npm/echarts-www-landing-animation/';
// Load script.
var link = document.createElement('link');
var script = document.createElement('script');