MCPcopy
hub / github.com/theajack/disable-devtool / formatName

Function formatName

src/plugins/script-use.ts:43–59  ·  view source on GitHub ↗
(name: string)

Source from the content-addressed store, hash-verified

41}
42
43function formatName (name: string) {
44 if (name.indexOf('-') === -1) {
45 return name;
46 }
47 let flag = false;
48 return name.split('').map(c => {
49 if (c === '-') {
50 flag = true;
51 return '';
52 }
53 if (flag) {
54 flag = false;
55 return c.toUpperCase();
56 }
57 return c;
58 }).join('');
59}

Callers 1

checkScriptUseFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected