Skip to content
Permalink
Browse files

Fix disqus implementation and update gemspec

  • Loading branch information...
chesterhow committed Oct 24, 2019
1 parent 3eeb6a6 commit 08b2409165523140314bacdbfd71949898c9560c
Showing with 33 additions and 57 deletions.
  1. +5 −11 README.md
  2. +3 −0 _config.yml
  3. +0 −2 _data/theme.yml
  4. +0 −30 _includes/disqus_comment.html
  5. +11 −0 _includes/disqus_comments.html
  6. +3 −2 _layouts/post.html
  7. +10 −11 assets/js/disqusLoader.js
  8. +1 −1 tale.gemspec
@@ -13,7 +13,7 @@ Tale is a minimal Jekyll theme curated for storytellers. Checkout the demo [here
- Syntax highlighting, with the help of Pygments
- Markdown and HTML text formatting
- Pagination of posts
- [Enabling Comments (via Disqus)](#enabling-comments-via-disqus)
- [Disqus comments (can be enabled if needed)](#enabling-comments)

## Installation
There are 3 ways to install this theme
@@ -113,20 +113,14 @@ $ bundle exec jekyll serve

And you're all set! Head over to http://127.0.0.1:4000/ to see your site in action.


### Enabling Comments (via Disqus)

Optionally, if you have a Disqus account, you can tell Jekyll to use it to show a comments section below each post.

To enable it, add the following lines to your Jekyll site:
### Enabling Comments
Comments are disabled by default. To enable them, look for the following line in `_config.yml` and change `jekyll-tale` to your site's Disqus id.

```yml
disqus: your_disqus_id
disqus: jekyll-tale
```

You can find out more about Disqus' shortnames [here](https://help.disqus.com/installation/whats-a-shortname).

Comments are disabled by default and will only appear in when adding `comments: true` to that post's YAML Front Matter
Next, add `comments: true` to the YAML front matter of the posts which you would like to enable comments for.

## Contributing
Found a bug or have a suggestion? Feel free to create an issue or make a pull request!
@@ -36,3 +36,6 @@ paginate: 5

# Excludes
exclude: [ Gemfile, Gemfile.lock, tale.gemspec ]

# Disqus (Set to your disqus id)
disqus: jekyll-tale

This file was deleted.

This file was deleted.

@@ -0,0 +1,11 @@
<!-- Start disqus -->
<script src="{{ "/assets/js/disqusLoader.js" | relative_url }}" /></script>
<div id="disqus_thread"><h3>Discussion and feedback</h3></div>
<div class="disqus"></div>
<script>
disqusLoader('.disqus', {
scriptUrl: 'https://{{ site.disqus }}.disqus.com/embed.js'
});
</script>
<noscript>Please enable JavaScript to view the <a href="https://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
<!-- End disqus -->
@@ -21,11 +21,12 @@ <h1 class="post-title">{{ page.title }}</h1>
<div class="post-line"></div>

{{ content }}

</div>

{% if page.comments %}
{% include disqus_comment.html %}
{% include disqus_comments.html %}
{% endif %}

<div class="pagination">
{% if page.next.url %}
<a href="{{ page.next.url | prepend: site.baseurl }}" class="left arrow">&#8592;</a>

Some generated files are not rendered by default. Learn more.

@@ -2,7 +2,7 @@

Gem::Specification.new do |spec|
spec.name = "tale"
spec.version = "0.1.5"
spec.version = "0.1.6"
spec.authors = ["Chester How"]
spec.email = ["chesterhow@gmail.com"]

0 comments on commit 08b2409

Please sign in to comment.
You can’t perform that action at this time.