Skip to content

Commit

Permalink
Adds page configuration for description (daattali#690)
Browse files Browse the repository at this point in the history
  • Loading branch information
lexicalunit committed Aug 8, 2020
1 parent 6e24421 commit 3021233
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,7 @@ nav-short | By default, the navigation bar gets shorter after scrolling down t
gh-repo   | If you want to show GitHub buttons at the top of a post, this sets the GitHub repo name (eg. `daattali/beautiful-jekyll`). You must also use the `gh-badge` parameter to specify what buttons to show.
gh-badge | Select which GitHub buttons to display. Available options are: [star, watch, fork, follow]. You must also use the `gh-repo` parameter to specify the GitHub repo.
layout | What type of page this is (default is `post` for blog posts and `page` for other pages). See _Page types_ section below for more information.
description | A longer description of page or blog post that is used for your meta description content.

## Advanced parameters

Expand Down
8 changes: 5 additions & 3 deletions _includes/head.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,14 @@
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">

<title>{% if page.use-site-title %}{{ site.title }} {{ site.title-separator | default: '-' }} {{ site.description }}{% elsif page.title %}{{ page.title }}{% else %}{{ site.title }}{% endif %}</title>

{% if site.author %}
<meta name="author" content="{{ site.author }}">
{% endif %}

{% if page.subtitle %}

{% if page.description %}
<meta name="description" content="{{ page.description }}">
{% elsif page.subtitle %}
<meta name="description" content="{{ page.subtitle }}">
{% endif %}

Expand Down

0 comments on commit 3021233

Please sign in to comment.