Skip to content

Commit

Permalink
doc: add getAllExtensions doc
Browse files Browse the repository at this point in the history
  • Loading branch information
broofa committed Sep 14, 2023
1 parent 9ee3f7b commit b3f35d1
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,17 @@ mime.getExtension('application/json'); // ⇨ 'json'
mime.getExtension('text/html; charset=utf8'); // ⇨ 'html'
```

### mime.getAllExtensions(type)

> **Note**
> New in `mime@4`
Get all extensions for the given mime type.

```javascript --run default
mime.getAllExtensions('image/jpeg'); // ⇨ Set(3) { 'jpeg', 'jpg', 'jpe' }
```

### mime.define(typeMap[, force = false])

Define [more] type mappings.
Expand Down

0 comments on commit b3f35d1

Please sign in to comment.