Hi everyone,
I’m currently moving my portfolio (www.samuelzeller.ch) running on SQS over to Ghost V2 (not self-hosted). I added Disqus comments on post.hbs using the “has” helper to trigger it only on posts who have the tag “journal” or “article” which are blog posts. The Disqus div is loading correctly on a page like this one: Domain error but only after I scroll down and refresh the browser. It’s not loading if I navigate back to blog and then back to the article, it doesn’t load on first page visit.
Any idea why it’s behaving like that?
Here’s how the snippet in my post.hbs looks like, it’s placed after /footer and before /article
{{#has tag="journal, article"}}
<div id="disqus_thread"></div>
<script>
var disqus_config = function () {
this.page.url = "{{url absolute="true"}}";
this.page.identifier = "ghost-{{comment_id}}"
};
(function() {
var d = document, s = d.createElement('script');
s.src = 'https://samuel-zeller.disqus.com/embed.js';
s.setAttribute('data-timestamp', +new Date());
(d.head || d.body).appendChild(s);
})();
</script>
{{/has}}