0x-jerry / vscode-hexo-utils

vscode sidebar for hexo.
https://marketplace.visualstudio.com/items?itemName=fantasy.vscode-hexo-utils
MIT License
46 stars 11 forks source link

Support for `asset_path` #47

Closed astroHaoPeng closed 2 years ago

astroHaoPeng commented 2 years ago

Is your feature request related to a problem? Please describe. Not related to any problem.

Describe the solution you'd like I'm using the code like this to control the figure width in my post,

<img src="{% asset_path figureName.png %}" width="600px" title="My figure.">

so that my image insertion won't depend on any third-party plugins to control the figure size, and the title can easily be rendered as a caption by another package. But this won't be rendered in the VS preview. So, I would like to get a support for the asset_path in your plugin.

I've tried to look into your implementation, the logic seems not impossible since you've already implemented the and asset_link support. However, it's beyond of my current capability. So, I hope you could take some time to look at this request. Many thanks.

Alternatives Any suggestion that can easily control the figure size is also welcomed. Thx.

0x-jerry commented 2 years ago

I have implemented it in v0.2.2, Please upgrade and try again.

Thanks for your feedback.

astroHaoPeng commented 2 years ago

It works flawlessly. Nice done! Thanks.