Skip to content

Commit cc5c7d3

Browse files
committed
forward docs root to index
1 parent bf17765 commit cc5c7d3

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

docs/main.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
import sys
33
from pathlib import Path
44

5-
from sanic import Sanic
5+
from sanic import Sanic, response
66

77
import idom
88
from idom.server.sanic import PerClientStateServer
@@ -15,6 +15,11 @@
1515
app.static("/", str(here / "build"))
1616

1717

18+
@app.route("/")
19+
async def forward_to_index(request):
20+
return response.redirect("/index.html")
21+
22+
1823
mount, component = multiview()
1924

2025
examples_dir = here / "source" / "examples"

0 commit comments

Comments
 (0)