hcoona/hexo-renderer-asciidoc

does not support fontawesome?

Closed this issue · 4 comments

this plugin does not support fontawesome?

It should be covered in hexo itself instead of the renderer module. The renderer modules take resonsibility of converting text from source format into target format. In particular, hexo-renderer-asciidoc help hexo converting text from ascidoc format to html format.

It should be covered in hexo itself instead of the renderer module. The renderer modules take resonsibility of converting text from source format into target format. In particular, hexo-renderer-asciidoc help hexo converting text from ascidoc format to html format.

Thanks for replying. You mentioned that hexo-renderer-asciidoc converts text to html format, I checked the generated html code and found that admonition block were converted to code like

<td class="icon">
<div class="title">Warning</div>
</td>

which was not a fontawesome-like code block:

<i class="fa fa-abacus"></i>

In fact, hexo did add fontawesome css to this html and fonts dir path was correct. If i add some plain html code like +++<i class="fa fa-abacus"></i>+++ , hexo could also generate a html with correct fontawesome icons displayed. I also use another asciidoc plugin in Intellij Idea and it works fine. So i wonder if there was something more could be done here?

maybe i misunderstood this plugin, i checked the renderer.js and realized maybe these work should be done by asciidoctor.js

Both of your idea are correct.

  1. The renderer should take responsibility of keeping compatible to hexo.
  2. The converting from asciidoc to html is so complex that I have to rely on the existing backend asciidoctor.js, which is not fully compatible to hexo.