hcz-jekyll-blog icon indicating copy to clipboard operation
hcz-jekyll-blog copied to clipboard

Support per-article icons/images

Open GreatEmerald opened this issue 8 years ago • 1 comments

Right now all items on the home page are statically set to use the fa-sticky-note icon. Instead, it would be nice if it made use of metadata inside a post, such as icon: fa-user or image: /images/my-thumbnail.png. Same goes for the posts-per-category view and the proposed collections-based projects.

GreatEmerald avatar Sep 04 '16 17:09 GreatEmerald

I just did this on my branch. All you need to do is modify this line to:

<img src= {{post.image}} />

Then the YAML image tags will work fine, like the following example:

---
layout: post
title: Distributing TMB code in R packages
comments: true
catagories: TMB R c++
image: https://upload.wikimedia.org/wikipedia/commons/thumb/1/1b/R_logo.svg/724px-R_logo.svg.png
---

RTbecard avatar Feb 18 '18 15:02 RTbecard