Versions in this module Expand all Collapse all v1 v1.0.3 Dec 30, 2025 Changes in this version + type CachePolicy interface + GetCacheHeaders func(path string) map[string]string + GetCacheTime func(path string) int + func ExtensionCache(rules map[string]int, defaultTime int) CachePolicy + func NoCache() CachePolicy + func SimpleCache(seconds int) CachePolicy + type FallbackStrategy interface + GetFallbackPath func(path string) string + ShouldFallback func(path string) bool + func DefaultExtensionFallback(fallbackPath string) FallbackStrategy + func ExtensionFallback(staticExtensions []string, fallbackPath string) FallbackStrategy + func HTMLFallback(indexFile string) FallbackStrategy + type FileSystemProvider interface + Close func() error + Open func(name string) (fs.File, error) + Type func() string + func EmbedProvider(embedFS *embed.FS, zipFile string) (FileSystemProvider, error) + func LocalProvider(path string) (FileSystemProvider, error) + func ZipProvider(zipPath string) (FileSystemProvider, error) + type MIMETypeResolver interface + GetMIMEType func(path string) string + RegisterMIMEType func(extension, mimeType string) + func DefaultMIMEResolver() MIMETypeResolver + type MountConfig struct + CachePolicy CachePolicy + FallbackStrategy FallbackStrategy + MIMEResolver MIMETypeResolver + Provider FileSystemProvider + URLPrefix string + type ReloadableProvider interface + Reload func() error + type ServiceConfig struct + DefaultCacheTime int + DefaultMIMETypes map[string]string + func DefaultServiceConfig() *ServiceConfig + func (c *ServiceConfig) Validate() error + type StaticFileService interface + Close func() error + Handler func() http.Handler + ListMounts func() []string + Mount func(config MountConfig) error + Reload func() error + Unmount func(urlPrefix string) error + func NewService(config *ServiceConfig) StaticFileService