MCPcopy Create free account
hub / github.com/nodejs/node / ensureTrailingDirectorySeparator

Function ensureTrailingDirectorySeparator

test/fixtures/snapshot/typescript.js:8022–8027  ·  view source on GitHub ↗
(path)

Source from the content-addressed store, hash-verified

8020 }
8021 ts.removeTrailingDirectorySeparator = removeTrailingDirectorySeparator;
8022 function ensureTrailingDirectorySeparator(path) {
8023 if (!hasTrailingDirectorySeparator(path)) {
8024 return path + ts.directorySeparator;
8025 }
8026 return path;
8027 }
8028 ts.ensureTrailingDirectorySeparator = ensureTrailingDirectorySeparator;
8029 /**
8030 * Ensures a path is either absolute (prefixed with `/` or `c:`) or dot-relative (prefixed

Callers 3

combinePathsFunction · 0.85
normalizePathFunction · 0.85

Calls 1

Tested by

no test coverage detected