Skip to content

Commit 0a51e8f

Browse files
authored
Update README.md
1 parent b40c48a commit 0a51e8f

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

README.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,15 @@ catch (Exception e) // the file size is probably over the OpenReadStream limit
5858
}
5959
```
6060

61+
## 💡 Custom MIME types
62+
63+
If you need to register custom MIME/file extension pairs, use `MimeTypeMap.AddMimeTypes`:
64+
```cs
65+
MimeTypeMap.AddMimeTypes([
66+
new KeyValuePair<string, string>(".js", "text/javascript")
67+
]);
68+
```
69+
6170
## 🎯 Examples
6271

6372
- [Blazor Server](https://github.com/lofcz/MimeTypeCore/blob/master/MimeTypeCore/MimeTypeCore.Example.Web/Components/Pages/Home.razor)

0 commit comments

Comments
 (0)