Spring boot provides default list of MIME content types from the below class
impot org.springframework.boot.web.server.MimeMappings;
Additional content types can be added using below example code for WebAssembly content type
@Configuration
class AppConfig : WebServerFactoryCustomizer<ConfigurableServletWebServerFactory> {
override fun customize(factory:ConfigurableServletWebServerFactory ) {
var mappings:MimeMappings = MimeMappings(MimeMappings.DEFAULT);
mappings.add("wasm", "application/wasm;charset=utf-8");
factory.setMimeMappings(mappings);
}
}
with above code a spring boot application can serve WebAssembly binaries
End Of Article