@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
trueif a string orPathinstance looks like a file system path, by checking for absolute or relative path markers, or the existence of path separating slashes. Will returnfalsefor values that are only the file or folder name.