Files
spacedrive/packages/interface/src/components/explorer/utils.ts
T
Jamie Pine cbd58ee438 Rename Files to Objects (#396)
* backend rename complete

* finalize Object refactor frontend
+ remove some exhaustive dep suppression
+ FIX INVALIDATE QUERY BUG
2022-10-04 09:16:49 -07:00

10 lines
313 B
TypeScript

import { ExplorerItem, FilePath } from '@sd/client';
export function isPath(item: ExplorerItem): item is Extract<ExplorerItem, { type: 'Path' }> {
return item.type === 'Path';
}
export function isObject(item: ExplorerItem): item is Extract<ExplorerItem, { type: 'Object' }> {
return item.type === 'Object';
}