Docs/Reference: Remove arguments from command slugs

This commit is contained in:
Starbeamrainbowlabs 2021-06-26 13:03:42 +01:00
parent 5b26bbc0b8
commit bf71aae1d3
Signed by: sbrl
GPG key ID: 1BE5172E637709C2

View file

@ -15,7 +15,8 @@ module.exports = function parse_sections(source) {
result.push({
title: htmlentities.encode(title),
slug: title.toLowerCase().replace(/[^a-z0-9-_\s]+/gi, "")
.replace(/\s+/g, "-"),
.replace(/\s+/g, "-")
.replace(/-.*$/, ""),
content: markdown.render(acc.slice(1).join("\n"))
});
}