本文整理匯總了TypeScript中vs/base/common/resources.removeTrailingPathSeparator函數的典型用法代碼示例。如果您正苦於以下問題:TypeScript removeTrailingPathSeparator函數的具體用法?TypeScript removeTrailingPathSeparator怎麽用?TypeScript removeTrailingPathSeparator使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。
在下文中一共展示了removeTrailingPathSeparator函數的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的TypeScript代碼示例。
示例1: assertRelativePath
function assertRelativePath(u1: URI, u2: URI, expectedPath: string | undefined, ignoreJoin?: boolean) {
assert.equal(relativePath(u1, u2), expectedPath, `from ${u1.toString()} to ${u2.toString()}`);
if (expectedPath !== undefined && !ignoreJoin) {
assertEqualURI(removeTrailingPathSeparator(joinPath(u1, expectedPath)), removeTrailingPathSeparator(u2), 'joinPath on relativePath should be equal');
}
}
示例2:
return workspaceEditingService.addFolders(folders.map(folder => ({ uri: resources.removeTrailingPathSeparator(folder) })))
示例3: assertRemoveTrailingSeparator
function assertRemoveTrailingSeparator(u1: URI, expected: URI) {
assertEqualURI(removeTrailingPathSeparator(u1), expected, u1.toString());
}