MCPcopy Create free account
hub / github.com/denoland/std / assertPath

Function assertPath

path/_common/assert_path.ts:4–10  ·  view source on GitHub ↗
(path?: string)

Source from the content-addressed store, hash-verified

2// Copyright the Browserify authors. MIT License.
3
4export function assertPath(path?: string) {
5 if (typeof path !== "string") {
6 throw new TypeError(
7 `Path must be a string, received "${JSON.stringify(path)}"`,
8 );
9 }
10}

Callers 15

assertArgFunction · 0.90
assertArgsFunction · 0.90
assertArgFunction · 0.90
assertArgsFunction · 0.90
resolveFunction · 0.90
isAbsoluteFunction · 0.90
extnameFunction · 0.90
parseFunction · 0.90
joinFunction · 0.90
resolveFunction · 0.90
isAbsoluteFunction · 0.90

Calls 1

stringifyMethod · 0.80

Tested by

no test coverage detected