Search code examples
jekyllnoscriptgist

Warning about <noscript> tag for gist when run jekyll server


I embeded a gist using {% gist octocat/0831f3fbd83ac4d46451 git-author-rewrite.sh %}, then I ran jekyll server, came this warning:

Regenerating: 1 file(s) changed at 2015-08-28 19:43:12
Warning: The tag for your gist octocat/0831f3fbd83ac4d46451 could not be generated. This will affect users who do not have JavaScript available or enabled in their browsers.
Warning: The tag for your gist octocat/0831f3fbd83ac4d46451 could not be generated. This will affect users who do not have JavaScript available or enabled in their browsers. ...done in 7.157032 seconds.

And the page generated looked strange: extra word displayed. Reason unknown.
Gem jekyll-gist has been installed already. What can I do with this? I googled for several hours, but with no luck.

Edit: Hmm, add pictures to show why this question came out:

  • noscript tag warning:

enter image description here

  • extra word 'true' displayed:

enter image description here


Solution

  • To close this issue, let me add something.
    Yes, this is related with proxy, and the jekyll (my version is 2.5.3). In my case, I ran jekyll server just behind the http proxy, and jekyll threw out a warning, generated this html code (I thought there may be something wrong):

    <p>true<script src="https://gist.github.com/octocat/0831f3fbd83ac4d46451.js?file=git-author-rewrite.sh"></script></p>
    

    So you can see the extra word 'true'.

    To avoid this, I just insert the script instead of embedded gist (retrieved from the generated code):

    <p><script src="https://gist.github.com/octocat/0831f3fbd83ac4d46451.js"></script></p>
    

    I recommend the audiences to use script instead of gist. There's another reason: if you want to run jekyll and overview site offline, the embedded gist will cause a connection error.