* Determines whether a path starts with an absolute path component (i.e. `/`, `c:/`, `file://`, etc.). * * ```ts * // POSIX * pathIsAbsolute("/path/to/file.ext") === true * // DOS * pathIsAbsolute("c:/path/to/file.ext") === true * // URL * pathIsAbsolute("file
(path)
| 7591 | * ``` |
| 7592 | */ |
| 7593 | function pathIsAbsolute(path) { |
| 7594 | return getEncodedRootLength(path) !== 0; |
| 7595 | } |
| 7596 | ts.pathIsAbsolute = pathIsAbsolute; |
| 7597 | /** |
| 7598 | * Determines whether a path starts with a relative path component (i.e. `.` or `..`). |
no test coverage detected
searching dependent graphs…