Add index page

This commit is contained in:
Mathias DUPEUX 2025-04-17 17:28:14 +02:00
parent 94a278dbd4
commit 005c1ab659
2 changed files with 25 additions and 1 deletions

View file

@ -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()