Browse Source

add disqus

pull/1/head
Brett Langdon 11 years ago
parent
commit
8ce9080e8e
2 changed files with 21 additions and 0 deletions
  1. +3
    -0
      templates/article.jade
  2. +18
    -0
      templates/mixins/disqus.jade

+ 3
- 0
templates/article.jade View File

@ -18,6 +18,9 @@ block content
article.article
section.content!= typogr(page.html).typogrify()
section.comments
+disqus
block prepend footer
div.nav
a(href=contents.index.url) « Full blog


+ 18
- 0
templates/mixins/disqus.jade View File

@ -0,0 +1,18 @@
mixin disqus
#disqus_thread
script(type="text/javascript").
var disqus_shortname = 'theworstprogrammerever';
var disqus_identifier = 'http://theworstprogrammerever.com#{page.url}';
var disqus_title = '#{page.title}';
var disqus_url = "http://theworstprogrammerever.com#{page.url}";
(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);
})();
noscript
| Please enable JavaScript to view the
a(href="http://disqus.com/?ref_noscript")=" comments powered by Disqus."
a(href="http://disqus.com").dsq-brlink
| comments powered by
span.logo-disqus=" Disqus"

Loading…
Cancel
Save