Is it possible to include external files when using Jade’s :markdown filter?

前端 未结 3 1565
忘掉有多难
忘掉有多难 2021-02-04 08:55

I\'m building an Express.js Node app and using Jade templates. Jade provides a :markdown filter which enables embedding Markdown code inside Jade:

h         


        
3条回答
  •  渐次进展
    2021-02-04 09:48

    You can include markdown files using the :md filter modifier.

    eg.

    html
      body
        include:md ../path/to/markdown/file.md
    

    Language Reference: https://pugjs.org/language/includes.html#including-filtered-text

提交回复
热议问题