Skip to content

Commit 8792f3a

Browse files
authored
Adding .mjs to list of known MIME types (#34318)
* Adding .mjs to list of known MIME types https://datatracker.ietf.org/doc/html/draft-ietf-dispatch-javascript-mjs has been submitted for publication to the IESG. We anticipate that browsers may start enforcing the correct `Content-Type` header for javascript modules prior to execution. As an aside, see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Modules#aside_%E2%80%94_.mjs_versus_.js
1 parent 25767de commit 8792f3a

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/Middleware/StaticFiles/src/FileExtensionContentTypeProvider.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,7 @@ public FileExtensionContentTypeProvider()
177177
{ ".mid", "audio/mid" },
178178
{ ".midi", "audio/mid" },
179179
{ ".mix", "application/octet-stream" },
180+
{ ".mjs", "text/javascript" },
180181
{ ".mmf", "application/x-smaf" },
181182
{ ".mno", "text/xml" },
182183
{ ".mny", "application/x-msmoney" },

0 commit comments

Comments
 (0)