Skip to contents

Extensions of a type

Usage

mime_extensions(type)

Arguments

type

A character vector of types. Aliases, parameters and case are ignored.

Value

A list with one character vector per type, the canonical extension first, without the dot. An unknown type gives character(0).

See also

mime_guess() for the reverse.

Other registry: mime_guess(), mime_is(), mime_parent(), mime_types()

Examples

mime_extensions(c("image/jpeg", "application/x-sqlite3"))
#> [[1]]
#> [1] "jpg"  "jpeg" "jpe" 
#> 
#> [[2]]
#> [1] "sqlite"  "sqlite3"
#>