Jekyll doesn't render Markdown when adding HTML

后端 未结 2 1053
自闭症患者
自闭症患者 2021-01-06 06:13

I have this markdown code in a Markdown file. It has inline HTML.

---
layout: page
title: About This Website
permalink: /about/
---


This website is built w         


        
2条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2021-01-06 06:31

    That's exactly how the original Markdown implementation works:

    Note that Markdown formatting syntax is not processed within block-level HTML tags. E.g., you can’t use Markdown-style *emphasis* inside an HTML block.

    Jekyll uses Redcarpet by default which behaves the same way. If you are running Jekyll yourself you might be able to create a custom Markdown processor to do what you want, but that won't work if you're using something like GitHub Pages for hosting.

提交回复
热议问题