extension-serve-static
serve-static based on file name extensions
based on serve-static
All in serve-static documentation is working here. But extension-serve-static add one mandatory parameter:
staticExtensions
staticExtensions is a white list of extensions names for serve, this allows something like this:
var connect = var extensionServeStatic = var app = // Serve up all folders for imagesapp
default extensions
For use the serve-static extensions parameter you must include de empty string ('') in the staticExtension list (as you see in the example).
mime types
extension-serve-static also search the extension in the mime types. If you need to add a non standard extension you can add it in the mime field
var connect = var extensionServeStatic = var mime = extensionServeStaticmime; mimetypesspecialimage = 'image/special'; var app = // Serve up all folders for imagesapp