Modularize pumpkin.js so it's easy to adapt, make main fetch posts(no creation yet), add very coooool countdown to Halloween with pumpkin carving visualization

This commit is contained in:
csd4ni3l
2025-10-23 19:52:54 +02:00
parent e238687a09
commit 9de0f728d5
7 changed files with 242 additions and 65 deletions

8
app.py
View File

@@ -71,9 +71,15 @@ def main():
cur.execute("SELECT * FROM Posts LIMIT 20")
posts = cur.fetchall()
cur.close()
return render_template("index.jinja2", username=username)
return render_template("index.jinja2", username=username, posts=posts)
@app.route("/countdown")
def countdown():
return render_template("countdown.jinja2", logged_in=flask_login.current_user.is_authenticated, grid_size=os.getenv("GRID_SIZE", 15))
@app.route("/login", methods=["GET", "POST"])
def login():