MCPcopy
hub / github.com/webpack/webpack / join

Function join

lib/util/fs.js:559–570  ·  lib/util/fs.js::join
(fs, rootPath, filename)

Source from the content-addressed store, hash-verified

557 * @returns {string} the joined path
558 */
559const join = (fs, rootPath, filename) => {
560 if (fs && fs.join) {
561 return fs.join(rootPath, filename);
562 } else if (path.posix.isAbsolute(rootPath)) {
563 return path.posix.join(rootPath, filename);
564 } else if (path.win32.isAbsolute(rootPath)) {
565 return path.win32.join(rootPath, filename);
566 }
567 throw new Error(
568 `${rootPath} is neither a posix nor a windows path, and there is no class="st">'join' method defined in the file system`
569 );
570};
571
572/**
573 * Returns the parent directory of the absolute path.

Callers 15

constructorMethod · 0.85
createSnapshotMethod · 0.85
_readContextMethod · 0.85
_getManagedItemInfoMethod · 0.85
getDiffToFsFunction · 0.85
applyDiffFunction · 0.85
applyMethod · 0.85
checkDependenciesMethod · 0.85
applyMethod · 0.85
_getEnvFilesForModeMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected