mirror of
https://github.com/oxen-io/session-desktop.git
synced 2023-12-14 02:12:57 +01:00
9 lines
398 B
TypeScript
9 lines
398 B
TypeScript
/**
|
|
* @prettier
|
|
*/
|
|
export type MIMEType = string & { _mimeTypeBrand: any };
|
|
|
|
export const isJPEG = (value: MIMEType): boolean => value === 'image/jpeg';
|
|
export const isImage = (value: MIMEType): boolean => value.startsWith('image/');
|
|
export const isVideo = (value: MIMEType): boolean => value.startsWith('video/');
|
|
export const isAudio = (value: MIMEType): boolean => value.startsWith('audio/');
|