Skip to content

Commit 109725d

Browse files
authored
fix(home): avoid LQIP dirty data passing to the next post (#1278)
1 parent e3b0163 commit 109725d

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

_layouts/home.html

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -47,10 +47,6 @@
4747
{% assign card_body_col = '12' %}
4848

4949
{% if post.image %}
50-
{% if post.image.lqip %}
51-
{% capture lqip %}lqip="{{ post.image.lqip }}"{% endcapture %}
52-
{% endif %}
53-
5450
{% assign src = post.image.path | default: post.image %}
5551
{% unless src contains '//' %}
5652
{% assign src = post.img_path | append: '/' | append: src | replace: '//', '/' %}
@@ -59,7 +55,7 @@
5955
{% assign alt = post.image.alt | xml_escape | default: 'Preview Image' %}
6056

6157
<div class="col-md-5">
62-
<img src="{{ src }}" alt="{{ alt }}" {{ lqip }}>
58+
<img src="{{ src }}" alt="{{ alt }}" {% if post.image.lqip %}lqip="{{ post.image.lqip }}"{% endif %}>
6359
</div>
6460

6561
{% assign card_body_col = '7' %}

0 commit comments

Comments
 (0)