Remove some whitespaces in generated html

This commit is contained in:
Nitan Alexandru Marcel 2021-03-05 13:32:41 +02:00 committed by GitHub
parent 8d28a8e87e
commit c187e6ae08
10 changed files with 32 additions and 31 deletions

View File

@ -24,4 +24,4 @@ sass:
plugins:
- jekyll-feed
- jekyll-seo-tag
- jekyll-seo-tag

View File

@ -11,8 +11,8 @@
{%- endif -%}
</title>
{% seo title=false %}
{% feed_meta %}
{%-seo title=false-%}
{%-feed_meta-%}
<link rel="shortcut icon" type="image/x-icon" href="{{ site.favicon | relative_url }}" />
<link rel="stylesheet" href="{{ "/assets/css/main.css" | relative_url }}" />

View File

@ -1,5 +1,5 @@
<ul>
{% for item in include.collection %}
{%-for item in include.collection-%}
<li>
{%- if item.url -%}
<a href="{{ item.url }}">{{ item.title }}</a>
@ -8,7 +8,7 @@
{%- endif -%}
</li>
{% if item.post_list %}
{%-if item.post_list-%}
{%
include post_list.html
category=item.post_list.category
@ -16,11 +16,11 @@
show_more=item.post_list.show_more
show_more_text=item.post_list.show_more_text
show_more_url=item.post_list.show_more_url
%}
{% endif %}
-%}
{%-endif-%}
{% if item.entries %}
{% include menu_item.html collection=item.entries %}
{% endif %}
{% endfor %}
{%-if item.entries-%}
{%-include menu_item.html collection=item.entries-%}
{%-endif-%}
{%-endfor-%}
</ul>

View File

@ -1,14 +1,14 @@
{% if include.category %}
{% assign posts = site.categories[include.category] %}
{% else %}
{% assign posts = site.posts %}
{% endif %}
{%-if include.category-%}
{%-assign posts = site.categories[include.category]-%}
{%-else-%}
{%-assign posts = site.posts-%}
{%-endif-%}
{% if include.limit and posts.size > include.limit %}
{% assign limit_exceeded = true %}
{% else %}
{% assign limit_exceeded = false %}
{% endif %}
{%-if include.limit and posts.size > include.limit-%}
{%-assign limit_exceeded = true-%}
{%-else-%}
{%-assign limit_exceeded = false-%}
{%-endif-%}
{%- if posts.size > 0 -%}
<ul>

View File

@ -2,8 +2,8 @@
layout: default
---
{% include back_link.html %}
{%-include back_link.html-%}
<h1>{{ page.title }}</h1>
{% include post_list.html category=page.which_category %}
{%-include post_list.html category=page.which_category-%}

View File

@ -8,8 +8,8 @@
</div>
</main>
{% if site.goat_counter and jekyll.environment == "production" %}
{% include goat_counter.html %}
{% endif %}
{%-if site.goat_counter and jekyll.environment == "production"-%}
{%-include goat_counter.html-%}
{%-endif-%}
</body>
</html>

View File

@ -3,11 +3,11 @@ layout: default
---
<header>
<h1>{{ site.title }}</h1>
{% if site.theme_config.show_description %}
{%-if site.theme_config.show_description-%}
<p>{{ site.description }}</p>
{% endif %}
{%-endif-%}
</header>
{% include menu_item.html collection=site.data.menu.entries %}
{%-include menu_item.html collection=site.data.menu.entries-%}
{{ content }}

View File

@ -2,7 +2,7 @@
layout: default
---
{% include back_link.html %}
{%-include back_link.html-%}
<h1>{{ page.title }}</h1>

View File

@ -2,7 +2,7 @@
layout: default
---
{% include back_link.html %}
{%-include back_link.html-%}
<article>
<p class="post-meta">

View File

@ -15,4 +15,5 @@ Gem::Specification.new do |spec|
spec.add_runtime_dependency "jekyll", "~> 3.8.7"
spec.add_runtime_dependency "jekyll-feed", "~> 0.13.0"
spec.add_runtime_dependency "jekyll-seo-tag", "~> 2.6.1"
end