Re-implement handling Liquid blocks in excerpts (#7250)

Merge pull request 7250
This commit is contained in:
Ashwin Maroli
2018-11-05 00:32:00 +05:30
committed by jekyllbot
parent b586bed0ee
commit 592b530de1
4 changed files with 79 additions and 37 deletions

View File

@@ -2,10 +2,23 @@
layout: post
---
{% if
page.layout == "post" %}
Youll find this post in your `_posts` directory.
To add new posts, simply add a file in the `_posts` directory.
{% endif %}
{%
highlight
ruby
%}
{% assign foo = 'foobar' %}
{% raw
%}
def print_hi(name)
puts "Hi, #{name}"
end
print_hi('Tom')
#=> prints 'Hi, Tom' to STDOUT.
{%
endraw
%}
{%
endhighlight
%}
So let's talk business.

View File

@@ -2,10 +2,20 @@
layout: post
---
{% if page.layout == "post" %}
Youll find this post in your `_posts` directory.
{%
highlight
ruby
%}
{% assign foo = 'foobar' %}
{% raw
%}
def print_hi(name)
puts "Hi, #{name}"
end
{% else %}
print_hi('Tom')
#=> prints 'Hi, Tom' to STDOUT.
{% endraw %}
{% endhighlight %}
To add new posts, simply add a file in the `_posts` directory.
{% endif %}
So let's talk business.