From 51163b167cce01af6101438e5e61145ad798f213 Mon Sep 17 00:00:00 2001 From: Mitsuo Tokumori Date: Sat, 8 Mar 2025 16:03:30 +0900 Subject: Restructure python code to be modular The python code is now a package named app. app/models: db models app/routes: flask blueprints app/static: css, js app/templates: jinja html templates --- README | 25 ++++++++++--------------- 1 file changed, 10 insertions(+), 15 deletions(-) (limited to 'README') diff --git a/README b/README index 71c0ae3..e4f195b 100644 --- a/README +++ b/README @@ -1,34 +1,29 @@ MASU - minimalist dashboard -what: grid of blocks (clocks, weather, etc) w/ real-time updates - -how: flask + vanilla js, no bloat - -why: simple, tweakable, fast +A web based grid of blocks (e.g., clocks, weather) with "real-time" +updates. Implemented in flask and vanilla js (trying to minimize bloat). +Features: simple, tweakable, fast. setup: git clone python -m venv .venv source .venv/bin/activate - pip install flask requests - flask run + pip install -r requirements.txt + python run.py use: http://localhost:5000 reload/tweak in header -files: - - app.py: server - static/: css, js - templates/: html - hack: - add blocks: app.py + script.js - set intervals: script.js + Each block is defined by: + * html: front-end elements (modify: app/templates/index.html) (for now) + * css: front-end design (modify: app/static/style.css) + * js: front-end code (new file: app/static/block_name.js) + * python: back-end code (app/routes/main.py, app/utils/block_name.py) deploy: -- cgit v1.2.3