You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is probably a feature of hexo and not easy to change.
If you don't use <!-- --> to escape the tag, it will be wrapped in <p></p> by the markdown renderer, which may have side effects on some tags or themes.
Check List
hexo version
to check)Expected behavior
Fyi, I'm using https://github.com/next-theme/hexo-theme-next.
with
I would expect two paragraphs generated.
Actual behavior
No paragraphs generated.
How to reproduce?
https://github.com/PeichengLiu/for-hexo-rendering-issue is ready for your convenience.
Is the problem still there under "Safe mode"?
No HTML generated.
Environment & Settings
Node.js & npm version(
node -v && npm -v
)Your site
_config.yml
(Optional)The only configuration I changed is
theme: next
, and no configuration for the theme itself.Hexo and Plugin version(
npm ls --depth 0
)Your package.json
package.json
Others
I tried to dig out the root cause and fix it. It seems to be related to the way how Hexo implements Tag Plugins. I change
hexo/lib/hexo/post.js
Lines 16 to 17 in ad05652
to
, and
hexo/lib/hexo/post.js
Lines 37 to 39 in ad05652
to
. It solves the problem above, while it breaks unit tests. Which is another part I do not quite understand. For example, should not the following test
hexo/test/scripts/hexo/post.js
Lines 1249 to 1276 in ad05652
expect
? With a single
\n
between texts, how canAnother Text
be wrapped in a paragraph?Finally, one another question, why Hexo is using an outdated
markedjs
with some copied code snippets and uncleared (to me) customization?Next
(in Chinese), 使用 label 标签外挂在开头时,会导致无法换行 #707Thanks for your work!
The text was updated successfully, but these errors were encountered: