mirror of
https://github.com/static-web-server/static-web-server.git
synced 2026-01-25 05:06:33 +00:00
* chore: format Markdown files with mdformat * chore: switch to mdformat config file * chore: add missing trailing slash * docs: add section about formatting Markdown files
704 B
704 B
Multiple index files
SWS allows to provide a list of files that will be used as an index for requests ending with the slash character (‘/’).
!!! info "Notes"
- Files are checked in the specified order from left to right.
- The option value can be a single index or comma-separated when multiple values.
- The default value is `index.html`.
This feature is disabled by default and can be controlled by the string list --index-files option or the equivalent SERVER_INDEX_FILES env.
Here is an example:
static-web-server -p 8787 -d ./public \
--index-files="index.html, index.htm, default.html"