MCPcopy
hub / github.com/callumalpass/tasknotes / normalizePath

Function normalizePath

tests/__mocks__/obsidian.ts:902–904  ·  view source on GitHub ↗
(path: string)

Source from the content-addressed store, hash-verified

900
901// Utility functions
902export function normalizePath(path: string): string {
903 return path.replace(/\\/g, '/').replace(/\/+/g, '/').replace(/^\//, '').replace(/\/$/, '');
904}
905
906export function stringifyYaml(obj: any): string {
907 return require('yaml').stringify(obj);

Callers 15

ensureFolderExistsFunction · 0.90
getPluginDataPathFunction · 0.90
normalizeTypesFolderMethod · 0.90
applyTemplateMethod · 0.90
resolveTemplateFileMethod · 0.90
createNoteFromICSMethod · 0.90
moveTaskMethod · 0.90
taskReferenceMatchesMethod · 0.90
normalizeTaskPathMethod · 0.90
withMutationContextMethod · 0.90
getMutationContextMethod · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected