MCPcopy Create free account
hub / github.com/Hashnode/starter-kit / sanitizeSlug

Method sanitizeSlug

packages/utils/renderer/headingSlugger.ts:11–13  ·  view source on GitHub ↗
(str: string)

Source from the content-addressed store, hash-verified

9 }
10
11 static sanitizeSlug(str: string): string {
12 return slug(sanitizeHtml(str, { allowedTags: [] }), { lower: true });
13 }
14
15 private doesHeadingExist(slug: string): boolean {
16 // eslint-disable-next-line no-prototype-builtins

Callers 1

getSlugMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected