<% if (theme.search && theme.search.enable) { %> <% } %> <% if (theme.services) { %> <% if (theme.services.scrollreveal == true) { %> <% } %> <% if (theme.services.nodewaves == true) { %> <% } %> <% if (theme.services.busuanzi == true) { %> <% } %> <% if (theme.services.fastclick == true) { %> <% } %> <% if (theme.services.share == true && config.mob && config.mob.app_key) { %> <% if (page.layout == 'post' && page.share != false) { %> <% } %> <% } %> <% var displayComments = false; if (page && theme.services) { if ((config.disqus_shortname || config.livere_uid || config.valine) && theme.services.comments == true && page.comments != false) { displayComments = true; } } %> <% if (displayComments == true) { %> <% if ((page.layout == 'post' && page.comments != false) || page.comments == true) { %> <% if (config.disqus_shortname){ %> <% } %> <% if (config.livere_uid){ %> <% } %> <% if (config.valine){ %> <% if (config.valine.enable && config.valine.app_id && config.valine.app_key){ %> <% if (theme.services.volantis == true) { %> <% if (theme.services && theme.services.cdn == true) { %> <% } else { %> <%- js('js/volantis.js') %> <% } %> <% } else { %> <% } %> <% } %> <% } %> <% } %> <% } %> <% if (theme.services.cdn == true && config.theme_cdn) { %> <% if (config.theme_cdn == true) { %> <%- js([theme.info.cdn + 'js/app.js', theme.info.cdn + 'js/search.js']) %> <% } else if (config.theme_cdn.length > 0) { %> <%- js([config.theme_cdn + 'js/app.js', config.theme_cdn + 'js/search.js']) %> <% } %> <% } else { %> <%- js(['js/app.js', 'js/search.js']) %> <% } %> <% } %> <% if (page.layout == 'links') { %> <%- js('https://cdn.jsdelivr.net/gh/toddmotto/echo@1.7.3/src/echo.js') %> <% } %> <% if (config.import && config.import.js && config.import.js.length > 0) { %> <%- js(config.import.js) %> <% } %> <% if (config.import && config.import.script && config.import.script.length > 0) { %> <% (config.import.script||[]).forEach(function(script){ %> <% }) %> <% } %>