1
0
mirror of https://github.com/node-red/node-red.git synced 2023-10-10 13:36:53 +02:00

Merge pull request #3362 from node-red/update-marked

Update marked to latest
This commit is contained in:
Nick O'Leary 2022-01-18 09:22:28 +00:00 committed by GitHub
commit 8b1f412255
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -107,7 +107,7 @@
"i18next-http-backend": "1.3.1", "i18next-http-backend": "1.3.1",
"jquery-i18next": "1.2.1", "jquery-i18next": "1.2.1",
"jsdoc-nr-template": "github:node-red/jsdoc-nr-template", "jsdoc-nr-template": "github:node-red/jsdoc-nr-template",
"marked": "3.0.7", "marked": "4.0.10",
"minami": "1.2.3", "minami": "1.2.3",
"mocha": "9.1.3", "mocha": "9.1.3",
"node-red-node-test-helper": "^0.2.7", "node-red-node-test-helper": "^0.2.7",

View File

@ -109,7 +109,7 @@ RED.utils = (function() {
window._marked.use({extensions: [descriptionList, description] } ); window._marked.use({extensions: [descriptionList, description] } );
function renderMarkdown(txt) { function renderMarkdown(txt) {
var rendered = _marked(txt); var rendered = _marked.parse(txt);
var cleaned = DOMPurify.sanitize(rendered, {SAFE_FOR_JQUERY: true}) var cleaned = DOMPurify.sanitize(rendered, {SAFE_FOR_JQUERY: true})
return cleaned; return cleaned;
} }