mimeTypes property

MimeTypeArray get mimeTypes

Returns a MimeTypeArray object, which contains a list of MimeType objects representing the MIME types recognized and supported by the browser. The array can be queried for information about the enabled plugin that is used to handle a file of the specified type. Named properties of the returned object are not enumerable (except in very old browser versions).

Recent versions of the specification hard-code the returned set of MIME types. If PDF files can be displayed inline then application/pdf and text/pdf are listed. Otherwise an empty list is returned.

Note: Use Navigator.pdfViewerEnabled to determine if inline viewing of PDF files is supported. Do not infer it from this property.

Legacy browser versions do not hard-code the list returned by the property, and might return other MIME types.

Implementation

external MimeTypeArray get mimeTypes;