wpt: allow mjs serve through test web server

This commit is contained in:
Pierre Tachoire
2025-12-15 08:50:12 +01:00
parent 447ef83e0a
commit ce85fa53b0

View File

@@ -100,6 +100,11 @@ fn getContentType(file_path: []const u8) []const u8 {
return "application/json";
}
if (std.mem.endsWith(u8, file_path, ".mjs")) {
// mjs are ECMAScript modules
return "application/json";
}
if (std.mem.endsWith(u8, file_path, ".html")) {
return "text/html";
}