Function: isValidMimeType()
isValidMimeType(
value):boolean
Defined in: src/types/atproto-validators.ts:256
Type guard for valid MIME type strings.
Parameters
value
string
Potential MIME type string
Returns
boolean
True if value is a valid MIME type format
Remarks
Validates MIME type format: type/subtype with optional parameters.
Common MIME types in Chive:
application/pdfimage/png,image/jpegapplication/ziptext/plain; charset=utf-8
This function validates format only, not whether the MIME type is registered with IANA.
Example
console.log(isValidMimeType('application/pdf')); // true
console.log(isValidMimeType('invalid')); // false