contentType

fun contentType(block: (Resource) -> ContentType?)

Configures ContentType for requested static content. If the block returns null, default behaviour of guessing ContentType from the header will be used. For files, Resource is a requested File. For resources, Resource is a URL to a requested resource.