timnew / hexo-tag-asset-res

Hexo Tag that consumes asset files
https://github.com/timnew/hexo-tag-asset-res
MIT License
17 stars 4 forks source link

Missing leading slash in generated img src value #1

Closed mgeeforce closed 10 years ago

mgeeforce commented 10 years ago

Awesomely useful renderer/generator! But I am finding that the img tag is being generated without the initial leading forward slash.

In my post:

title: test post
date: 2014-08-25 12:07:53
tags:

---
{% asset_img pam.png %}

and then in the generated file in public/2014/08/25/test-post/index.html:

<div class="article-entry" itemprop="articleBody">

    <img src="2014/08/25/test-post/pam.png"></img>

</div>
jimthedev commented 10 years ago

I am experiencing this as well.

timnew commented 10 years ago

Issue should be fixed in v0.1.2 Please help to verify

mgeeforce commented 10 years ago

Awesome! Verified fixed in v0.1.2. Thanks!

jimthedev commented 10 years ago

Worked for me with the following sequence of commands:

npm install hexo-tag-asset-res --save
hexo clean
hexo generate
hexo server -s

Thanks very much for the quick fix!

timnew commented 10 years ago

:smiley: