Skip to content

Commit 43db794

Browse files
authored
docs(tokenizer): utilise escapeHTML() (#222)
- marked internal escape() is no longer exported - continue #214
1 parent 4304601 commit 43db794

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ dompurify: true
117117
Or you can enable specific DOMPurify options (but according to DOMPurify authors, the default options are safe):
118118

119119
```yml
120-
dompurify:
120+
dompurify:
121121
FORBID_TAGS:
122122
- "style"
123123
```
@@ -195,7 +195,7 @@ Notice `renderer.heading = function (text, level) {` corresponds to [this line](
195195
It is also possible to customize the [tokenizer](https://marked.js.org/using_pro#tokenizer).
196196

197197
``` js
198-
const { escape } = require('marked/src/helpers');
198+
const { escapeHTML: escape } = require('hexo-util');
199199

200200
// https://github.com/markedjs/marked/blob/b6773fca412c339e0cedd56b63f9fa1583cfd372/src/Lexer.js#L8-L24
201201
// Replace dashes only

0 commit comments

Comments
 (0)