Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add html_as_default_extension option to ServeDir #519

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

its-the-shrimp
Copy link

Motivation

It's common for file servers to add an .html file extension to the requested path if no file extension is provided, to allow for more concise & human-readable links, e.g. for a request of /dashboard, return /dashboard.html

Solution

Add a html_as_default_extension option to the ServeDir service, which will be true by default, to be in tune with append_index_html_on_directories

This mirrors the common behaviour of file servers
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant