Documentation
¶
Index ¶
Constants ¶
View Source
const ( CacheControlImmutableAssets = "public, max-age=31536000, immutable" // 1 year CacheControlRootAssets = "public, max-age=86400" // 1 day CacheControlDocuments = "no-cache, must-revalidate" )
Variables ¶
This section is empty.
Functions ¶
func SetupStaticFileServing ¶
SetupStaticFileServing configures the Fiber app to serve static files. In dev mode, it proxies all requests to the Vite dev server (with an optional fallback to ./public). In production, it serves embedded static assets from the provided fs.FS, with support for user-provided assets in ./public that take precedence over embedded ones.
webFS should be an fs.FS containing the embedded frontend assets (if in prod mode)
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.