From 64e913f44e1bf877ba45199fa2c3b6ee7f179f38 Mon Sep 17 00:00:00 2001 From: Aevann1 Date: Sun, 12 Dec 2021 21:56:11 +0200 Subject: [PATCH] fdsdf --- files/__main__.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/files/__main__.py b/files/__main__.py index 41b97b033..49de05b05 100644 --- a/files/__main__.py +++ b/files/__main__.py @@ -3,6 +3,7 @@ gevent.monkey.patch_all() from os import environ import secrets from flask import * +from flask_assets import Bundle, Environment from flask_caching import Cache from flask_limiter import Limiter from flask_compress import Compress @@ -88,6 +89,13 @@ cache = Cache(app) Compress(app) mail = Mail(app) +assets = Environment(app) +css = Bundle('src/main.css', output='dist/main.css', filters='postcss') + +assets.register('css', css) +css.build() + + @app.before_request def before_request(): @@ -115,6 +123,10 @@ def before_request(): elif "Mobile/" in ua: g.system="ios/webview" else: g.system="other/other" +@app.get('/tw') +def get_tailwind(): + return render_template('tailwind.html') + @app.teardown_appcontext def teardown_request(error): if hasattr(g, 'db') and g.db: