@boost/commonFunctionsisFilePathisFilePath CallableisFilePath(path: PortablePath): booleanReturns true if a string or Path instance looks like a file system path, by checking for absolute or relative path markers, or the existence of path separating slashes. Will return false for values that are only the file or folder name. import { isFilePath } from '@boost/common';isFilePath('./path/to/file.ts'); // trueisFilePath(new Path('/path/to/folder')); // trueisFilePath('file.ts'); // false
Returns
true
if a string orPath
instance looks like a file system path, by checking for absolute or relative path markers, or the existence of path separating slashes. Will returnfalse
for values that are only the file or folder name.