hexo/node_modules/hexo-theme-butterfly/layout/includes/third-party/card-post-count/valine.pug

21 lines
557 B
Plaintext
Raw Normal View History

2023-09-25 15:58:56 +08:00
script.
(() => {
function loadValine () {
function initValine () {
let initData = {
el: '#vcomment',
appId: '#{theme.valine.appId}',
appKey: '#{theme.valine.appKey}',
serverURLs: '#{theme.valine.serverURLs}'
}
const valine = new Valine(initData)
}
if (typeof Valine === 'function') initValine()
else getScript('!{url_for(theme.asset.valine)}').then(initValine)
}
window.pjax ? loadValine() : window.addEventListener('load', loadValine)
})()