..
jekyll markdown internal links
There is no need to include the file extension when using the post_url
tag.
[Some Link]({% post_url 2010-07-21-name-of-post %})
1 2- if you want to include a link to a post on your site, the
post_url
tag will generate the correct permalink URL for the post you specify.{% post_url 2010-07-21-name-of-post %}
- if you organize your posts in subdirectories, you need to include subdirectory path to the post:
{% post_url /subdir/2010-07-21-name-of-post %}
- if you want to include a link to a post on your site, the
troubleshooting
- post_url generates urls without baseurl
- the
post_url
andlink
tags prefixessite.baseurl
from Jekyll 4.0 onward. {% post_url ... %}
is meant for posts only. For everything else, please use{% link ... %}
[article 1]({{site.baseurl}}/{% post_url DATE-article1.md %})
- the