Both of their elements can be accessed by for..in
, and the way of adding categories and tags are the same. So, what's the difference between categories and tags in Jekyll?
Tags and categories on posts are used to help readers locate information in different ways. Categories are like chapters of a book; they provide a general overview of the topics you blog about. Whereas tags are more like the index at the back of the book and explode the topic into a million bits.
Categories are best used for broad groupings of topics. For example, if you're creating a site that reviews media, you might use categories such as Books or Film or TV. Tags are much more specific topics that you want to use to associate related content.
Categories and tags are the two primary ways to group content on a WordPress site. In simple terms, categories are general labels, while tags are more specific (describe your posts in more detail).
It seems to me that the only important difference is that categories can be used in the post url - a post inside the "beer" and "food" categories, by default, will have this url:
/food/beer/2008/09/09/foo-bar.html
Instead of this one:
/2008/09/09/foo-bar.html
See the post tests for details
Tags have no influence in the urls, at least according to their tests.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With