Closed hanchn closed 6 years ago
兄弟,如果你不需要valine,可以把Anatole\layout\partial\comments.jade文件的这段代码屏蔽了,就可以生成了;我不是太懂jade语法,所以没法去修改。 if theme.duoshuo a#comments .ds-thread(data-thread-key=page.path, data-title=page.title, data-url=page.permalink, data-author-key='1') script. var duoshuoQuery = {short_name:"#{theme.duoshuo}"}; (function() { var ds = document.createElement('script'); ds.type = 'text/javascript';ds.async = true; ds.src = (document.location.protocol == 'https:' ? 'https:' : 'http:') + '//static.duoshuo.com/embed.js'; ds.charset = 'UTF-8'; (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(ds); })();
if theme.disqus a#comments
script.
var disqus_shortname = '#{theme.disqus}';
var disqus_identifier = '#{page.path}';
var disqus_title = '#{page.title}';
var disqus_url = '#{config.url}/#{page.path}';
(function() {
var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
(document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
})();
script(id='dsq-count-scr' src='//#{theme.disqus}.disqus.com/count.js' async)
if theme.gentie a#comments
script(src='https://img1.cache.netease.com/f2e/tie/yun/sdk/loader.js')
script.
var cloudTieConfig = { url: document.location.href, sourceId: '#{page.path}', productKey: '#{theme.gentie}', target: 'cloud-tie-wrapper' };var yunManualLoad = true;Tie.loader("aHR0cHM6Ly9hcGkuZ2VudGllLjE2My5jb20vcGMvbGl2ZXNjcmlwdC5odG1s", true);
if theme.youyan a#comments
script.
(function() {
var YYDiv = document.createElement('div');
YYDiv.id = 'uyan_frame';
document.getElementById('youyan_thread').appendChild(YYDiv);
var YYScript = document.createElement('script');
YYScript.type = 'text/javascript';
YYScript.async = true;
YYScript.src = (document.location.protocol == 'https:' ? 'https:' : 'http:') + '//v2.uyan.cc/code/uyan.js?uid=' + '#{theme.youyan}';
YYScript.charset = 'UTF-8';
document.getElementById('youyan_thread').appendChild(YYScript);
})();
//if theme.valine.enable == true // a#comments // #vcomments(style="margin:0 30px;") // script(src='//cdn1.lncld.net/static/js/3.0.4/av-min.js') // script(src='//cdn.jsdelivr.net/gh/xcss/valine@v1.1.7/dist/Valine.min.js' + '?v=' + theme.version) // script. // var valine = new Valine({ // el:'#vcomments', // notify:#{theme.valine.notify} || false, // verify:#{theme.valine.verify}|| false, // app_id:'#{theme.valine.appid}', // app_key:'#{theme.valine.appkey}', // placeholder:'#{theme.valine.placeholder}', // path: window.location.pathname, // avatar:'#{theme.valine.avatar}' // })
报错信息如下 Cannot read property 'enable' of undefined
导致无法生成页面