MCPcopy Index your code
hub / github.com/massCodeIO/massCode / normalizeImportTag

Function normalizeImportTag

src/main/import/snippets/normalizers.ts:54–65  ·  view source on GitHub ↗
(value: unknown)

Source from the content-addressed store, hash-verified

52}
53
54export function normalizeImportTag(value: unknown): string | null {
55 if (typeof value !== 'string') {
56 return null
57 }
58
59 const normalized = value
60 .trim()
61 .replace(/^#+/, '')
62 .replace(/[\\/]+/g, '-')
63 .trim()
64 return normalized || null
65}
66
67export function uniqueStrings(values: string[]): string[] {
68 const result: string[] = []

Callers 5

getOrCreateTagIdsFunction · 0.90
getPrefixTagsFunction · 0.90
buildTagMapFunction · 0.90
getTagsFunction · 0.90
getOrCreateTagIdsFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected