Sha256: d64a6689de678db7c8efc51d4c9a54ff6e490c566f967075c64b20ae63bf9ade
Contents?: true
Size: 534 Bytes
Versions: 47
Compression:
Stored size: 534 Bytes
Contents
# Static This middleware serves static files using the `mime-types` library. By default, it works with `Rack::Sendfile` and supports `ETag` based caching. Normally, you'd prefer to put static files into `public/_static` but it's also acceptable to put static content into `pages/` if it makes sense. ```ruby use Utopia::Static, # The root path to serve files from: root: "path/to/root", # The mime-types to recognize/serve: types: [:default, :xiph], # Cache-Control header for files: cache_control: 'public, max-age=7200' ```
Version data entries
47 entries across 47 versions & 1 rubygems