MCPcopy Create free account
hub / github.com/dailydotdev/apps / cleanTitle

Function cleanTitle

packages/shared/src/hooks/useRecentPages.ts:17–18  ·  view source on GitHub ↗
(title: string)

Source from the content-addressed store, hash-verified

15
16const brandSuffix = /\s*[|·\-–—]\s*daily\.dev\s*$/i;
17const cleanTitle = (title: string): string =>
18 title.replace(brandSuffix, '').trim();
19
20// Classify by the route template (router.pathname), not the resolved URL — only
21// the template distinguishes a user profile (`/[userId]`) from other top-level

Callers 1

captureFunction · 0.85

Calls 1

replaceMethod · 0.80

Tested by

no test coverage detected