MCPcopy Create free account
hub / github.com/Mrinank-Bhowmick/python-beginner-projects / slugify

Function slugify

web/scripts/gen-catalog.mjs:130–134  ·  view source on GitHub ↗
(s)

Source from the content-addressed store, hash-verified

128}
129
130const slugify = (s) =>
131 s
132 .toLowerCase()
133 .replace(/[^a-z0-9]+/g, "-")
134 .replace(/^-+|-+$/g, "") || "project";
135
136function findReadme(dir) {
137 for (const f of fs.readdirSync(dir)) {

Callers 2

pickFunction · 0.85
gen-catalog.mjsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected