Add index page
This commit is contained in:
parent
94a278dbd4
commit
005c1ab659
2 changed files with 25 additions and 1 deletions
6
main.py
6
main.py
|
@ -1,4 +1,4 @@
|
|||
from flask import Flask, request, make_response
|
||||
from flask import Flask, request, make_response, render_template
|
||||
from dotenv import load_dotenv
|
||||
from flask_sock import Sock
|
||||
from glob import glob
|
||||
|
@ -129,6 +129,10 @@ def websocket(ws):
|
|||
if operation == "usernames": # TODO
|
||||
ws.send(json.dumps({"1": "Mathias"}))
|
||||
|
||||
@app.route("/")
|
||||
def index():
|
||||
return render_template("index.html")
|
||||
|
||||
@app.route("/user/info", methods=["POST", "OPTIONS"])
|
||||
def user_info():
|
||||
if request.method == "OPTIONS": return make_resp()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue