From 714a0302ecb340be7159dd49d3e31c6e83b61582 Mon Sep 17 00:00:00 2001 From: Bui Date: Tue, 15 Feb 2022 21:21:19 +0000 Subject: [PATCH] serve src and assets on debug server --- app.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/app.py b/app.py index a9a35dc..8fd1e55 100644 --- a/app.py +++ b/app.py @@ -689,4 +689,13 @@ def make_preview(song_id, song_type, song_ext, preview): if __name__ == '__main__': + from flask import send_from_directory + @app.route('/src/') + def send_src(path): + return send_from_directory('public/src', path) + + @app.route('/assets/') + def send_assets(path): + return send_from_directory('public/assets', path) + app.run(port=34801)