hexojs / hexo-html-minifier

Minify HTML files with HTMLMinifier.
MIT License
27 stars 12 forks source link

Latex Render Error (for < and >) #66

Closed sshwy closed 4 years ago

sshwy commented 4 years ago

For example:

---
title: Test
date: 2020-06-19 17:44:15
tags:
---

## Test

$a\le b$.

$$
a \le b
$$

$a<b>c$.

$$
a<b
$$

$a<b$, $a>v$.

If a < and a > appear in the same paragraph (like $a<b$, $a>v$) or in the same inline math (like $a<b>c$), they wont escape to &lt; or &gt;. This will make error (Parse Error) while generating static files (although the error isn't thrown for this example, it is for another file of me).

SukkaW commented 4 years ago

@sshwy

What makes you believe it is an error of hexo-html-minifier?

If you uninstall hexo-html-minifier on run Hexo in safe mode (that will disable all the plugins and scripts), will the issue disappear?

Would you mind posting your the content of your post or at least provides the formula causing the error? It will also be appreciated if you upload the rendered result.

I am not sure, but it seems that the issue could be fixed by https://github.com/hexojs/hexo/pull/4073 .

sshwy commented 4 years ago

I find that it's not an error of hexo-html-minifier but of my renderer :disappointed:

Sorry for taking your time. I've fixed it.