Skip to content

Commit

Permalink
chore: update marked to version 0.6.0 (#768)
Browse files Browse the repository at this point in the history
The new release includes markedjs/marked#1383.
  • Loading branch information
lpinca authored and RomanHotsiy committed Jan 17, 2019
1 parent a419303 commit 02f6e18
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 11 deletions.
4 changes: 2 additions & 2 deletions package.json
Expand Up @@ -67,7 +67,7 @@
"@types/lodash": "^4.14.118",
"@types/lunr": "^2.1.6",
"@types/mark.js": "^8.11.1",
"@types/marked": "^0.4.2",
"@types/marked": "^0.6.0",
"@types/prismjs": "^1.6.4",
"@types/prop-types": "^15.5.6",
"@types/react": "^16.7.7",
Expand Down Expand Up @@ -139,7 +139,7 @@
"json-schema-ref-parser": "^6.0.1",
"lunr": "^2.3.2",
"mark.js": "^8.11.1",
"marked": "^0.5.2",
"marked": "^0.6.0",
"memoize-one": "^4.0.0",
"mobx-react": "^5.2.5",
"openapi-sampler": "1.0.0-beta.14",
Expand Down
4 changes: 2 additions & 2 deletions src/services/MarkdownRenderer.ts
Expand Up @@ -118,7 +118,7 @@ export class MarkdownRenderer {
.trim();
}

headingRule = (text: string, level: number, raw: string) => {
headingRule = (text: string, level: number, raw: string, slugger: marked.Slugger) => {
if (level === 1) {
this.currentTopHeading = this.saveHeading(text, level);
} else if (level === 2) {
Expand All @@ -129,7 +129,7 @@ export class MarkdownRenderer {
this.currentTopHeading && this.currentTopHeading.id,
);
}
return this.originalHeadingRule(text, level, raw);
return this.originalHeadingRule(text, level, raw, slugger);
};

renderMd(rawText: string, extractHeadings: boolean = false): string {
Expand Down
15 changes: 8 additions & 7 deletions yarn.lock
Expand Up @@ -768,10 +768,10 @@
dependencies:
"@types/jquery" "*"

"@types/marked@^0.4.2":
version "0.4.2"
resolved "https://registry.yarnpkg.com/@types/marked/-/marked-0.4.2.tgz#64a89e53ea37f61cc0f3ee1732c555c2dbf6452f"
integrity sha512-cDB930/7MbzaGF6U3IwSQp6XBru8xWajF5PV2YZZeV8DyiliTuld11afVztGI9+yJZ29il5E+NpGA6ooV/Cjkg==
"@types/marked@^0.6.0":
version "0.6.0"
resolved "https://registry.yarnpkg.com/@types/marked/-/marked-0.6.0.tgz#e4ac316144a84afda5c2474488d7b9fef3ab9995"
integrity sha512-TxwhgR9VsIfRDJ3WwFokG8Xu+ea0nYGDRHdI783WJ983uffatz0ytIeUEIBOwPvRy241KRSNVyywQltuTqDh0w==

"@types/minimatch@3.0.3":
version "3.0.3"
Expand Down Expand Up @@ -6257,9 +6257,10 @@ mark.js@^8.11.1:
resolved "https://registry.yarnpkg.com/mark.js/-/mark.js-8.11.1.tgz#180f1f9ebef8b0e638e4166ad52db879beb2ffc5"
integrity sha1-GA8fnr74sOY45BZq1S24eb6y/8U=

"marked@https://github.com/markedjs/marked#fb48827":
version "0.5.1"
resolved "https://github.com/markedjs/marked#fb48827236ed3a43e611d2adb3c070ca3f55ed8e"
marked@^0.6.0:
version "0.6.0"
resolved "https://registry.yarnpkg.com/marked/-/marked-0.6.0.tgz#a18d01cfdcf8d15c3c455b71c8329e5e0f01faa1"
integrity sha512-HduzIW2xApSXKXJSpCipSxKyvMbwRRa/TwMbepmlZziKdH8548WSoDP4SxzulEKjlo8BE39l+2fwJZuRKOln6g==

math-random@^1.0.1:
version "1.0.1"
Expand Down

0 comments on commit 02f6e18

Please sign in to comment.