onury / docma

A powerful tool to easily generate beautiful HTML documentation from JavaScript (JSDoc), Markdown and HTML files.
https://onury.io/docma
MIT License
334 stars 34 forks source link

HTML in markdown failed to render #75

Open takase1121 opened 5 years ago

takase1121 commented 5 years ago

https://takase1121.github.io/Haruna/ The failed p and img tags are pretty obvious. Can I get them to work?

onury commented 5 years ago

Pls paste or attach your docma.json / config.

takase1121 commented 5 years ago
{
    "src": [
        "./src/*.js",
        "./README.md"
    ],
    "dest": "./docs",
    "clean": true,
    "jsdoc": {
        "plugins": ["plugins/markdown"]
    },
    "app": {
        "title": "Haruna Documentation",
        "entrance": "content:readme",
        "base": "/Haruna",
        "routing": {
            "method": "path"
        }
    }
}
onury commented 5 years ago

Pls remove "plugins": ["plugins/markdown"] from your config. Docma includes a markdown parser.

takase1121 commented 5 years ago

The problem with HTML tag still persists. Not only that, If I disable jsdoc markdown plugin markdown in jsdoc is now ignored! Any ideas on how to fix it?

onury commented 5 years ago

Can you upload a sample project for me to reproduce the problem? I'll try to look into it tomorrow.

Just zip, then drag & drop here pls.

takase1121 commented 5 years ago

Haruna.zip This should be it. Thank you!

takase1121 commented 5 years ago

I got it! I turned markdown.sanitize to false in docma config and it worked!

JRJurman commented 5 years ago

I had to do this as well to get html in markdown to work. It says in the docs that it's by default set to false... Do the docs need to be updated?