Document versions.json
workaround when a server doesn't automatically forward to index.html
#276
Labels
documentation
Improvements or additions to documentation
I found the version switcher does not work out-of-the box when the server where the documentation is deployed doesn't forward a request to a directory (e.g. "docs/2.0/") to the
index.html
in that directory (e.g. "docs/2.0/index.html").I did find a way to make this work though, which may be nice to document for others that encounter this problem.
Instead of the regular versions.json
I used the following
Since the redirect URL is built as:
${base_url}/../${version}/
(source) this will now create a link directly to theindex.html
page. The folder name is included in thealiases
field such that thesetupVersionSelector
(source) can still find out which version you're looking at.The text was updated successfully, but these errors were encountered: