04/19 Continue fixing the UI issues with Chrome
This commit is contained in:
+5
-1
@@ -31,6 +31,10 @@ def create_app(config_name: str = 'development') -> Flask:
|
||||
cors_origins = app.config.get('CORS_ORIGINS', '*')
|
||||
CORS(app, resources={r'/api/*': {'origins': cors_origins}})
|
||||
|
||||
# Inject static asset version into every template for cache-busting.
|
||||
# Usage in templates: {{ url_for('static', filename='css/app.css') }}?v={{ sv }}
|
||||
app.jinja_env.globals['sv'] = app.config.get('STATIC_VERSION', '1')
|
||||
|
||||
# Attach security headers to every response
|
||||
@app.after_request
|
||||
def set_security_headers(response):
|
||||
@@ -111,4 +115,4 @@ def create_app(config_name: str = 'development') -> Flask:
|
||||
def recover_page():
|
||||
return render_template('auth/recover.html')
|
||||
|
||||
return app
|
||||
return app
|
||||
Reference in New Issue
Block a user