From 682c1a8200153f13367eb5f2a309a3c8d3e3cb3a Mon Sep 17 00:00:00 2001 From: wizardforcel <562826179@qq.com> Date: Mon, 23 Nov 2020 12:27:51 +0800 Subject: [PATCH] 2020-11-23 12:27:51 --- asset/docsify-baidu-push.js | 13 +++++++++++++ index.html | 2 ++ 2 files changed, 15 insertions(+) create mode 100644 asset/docsify-baidu-push.js diff --git a/asset/docsify-baidu-push.js b/asset/docsify-baidu-push.js new file mode 100644 index 00000000..27b1f742 --- /dev/null +++ b/asset/docsify-baidu-push.js @@ -0,0 +1,13 @@ +(function(){ + var plugin = function(hook) { + hook.doneEach(function() { + new Image().src = + '//api.share.baidu.com/s.gif?r=' + + encodeURIComponent(document.referrer) + + "&l=" + encodeURIComponent(location.href) + }) + } + var plugins = window.$docsify.plugins || [] + plugins.push(plugin) + window.$docsify.plugins = plugins +})() \ No newline at end of file diff --git a/index.html b/index.html index 60f6c751..0ea7e5c8 100644 --- a/index.html +++ b/index.html @@ -91,5 +91,7 @@ + +