MCPcopy Create free account
hub / github.com/SethGammon/Citadel / slug

Function slug

scripts/stack-plan.js:41–50  ·  view source on GitHub ↗
(value)

Source from the content-addressed store, hash-verified

39}
40
41function slug(value) {
42 return String(value || 'stack')
43 .replace(/\\/g, '/')
44 .split('/')
45 .filter(Boolean)
46 .join('-')
47 .replace(/[^a-zA-Z0-9._-]+/g, '-')
48 .replace(/^-+|-+$/g, '')
49 || 'stack';
50}
51
52function readText(filePath) {
53 try {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected