MCPcopy Index your code
hub / github.com/codebymitch/TitanBot / formatCategoryName

Function formatCategoryName

src/config/commandCategories.js:36–41  ·  view source on GitHub ↗
(rawCategory)

Source from the content-addressed store, hash-verified

34}
35
36export function formatCategoryName(rawCategory) {
37 return String(rawCategory || '')
38 .replace(/_/g, ' ')
39 .replace(/([a-z])([A-Z])/g, '$1 $2')
40 .replace(/\b\w/g, (char) => char.toUpperCase());
41}
42
43export function getCategoryIcon(category) {
44 return CATEGORY_ICONS[category] || CATEGORY_ICONS[formatCategoryName(category)] || '📁';

Callers 1

getCategoryIconFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected