You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I use quotes in my titles, the JavaScript at the end of the file renders like this: var disqus_title = '"Conway's Game of Life with an Arduino and an 8x8 LED Array"';
This throws Uncaught SyntaxError: Unexpected identifier and prevents Disqus from loading at all.
You're correct. This is my error. I was working off an older version of Pixyll in which disqus_title is surrounded by single quotes. It works fine without them, so I just need to update my own copy of the code. Thanks for the catch.
When I use quotes in my titles, the JavaScript at the end of the file renders like this:
var disqus_title = '"Conway's Game of Life with an Arduino and an 8x8 LED Array"';
This throws
Uncaught SyntaxError: Unexpected identifier
and prevents Disqus from loading at all.Here's the offending line:
pixyll/_layouts/post.html
Line 42 in de5c9fc
I found that if I change
jsonify
toescape
then it works correctly.Code in
post.html
:var disqus_title = '{{ page.title | escape }}';
Now it renders like so:
var disqus_title = 'Conway's Game of Life with an Arduino and an 8x8 LED Array';
And Disqus loads correctly.
I'm happy to submit a pull for this if others think that it's an improvement.
The text was updated successfully, but these errors were encountered: