docma icon indicating copy to clipboard operation
docma copied to clipboard

HTML in markdown failed to render

Open takase1121 opened this issue 6 years ago • 8 comments

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

takase1121 avatar Mar 17 '19 20:03 takase1121

Pls paste or attach your docma.json / config.

onury avatar Mar 18 '19 00:03 onury

{
    "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"
        }
    }
}

takase1121 avatar Mar 18 '19 06:03 takase1121

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

onury avatar Mar 19 '19 02:03 onury

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?

takase1121 avatar Mar 19 '19 10:03 takase1121

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.

onury avatar Mar 19 '19 13:03 onury

Haruna.zip This should be it. Thank you!

takase1121 avatar Mar 19 '19 14:03 takase1121

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

takase1121 avatar Mar 24 '19 05:03 takase1121

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?

JRJurman avatar May 31 '19 01:05 JRJurman