Repository for my studies. Anyone can clone and use this repository for studies.
Use #file:installation.py to install project dependencies from requirements.txt.
The script centralizes dependency installation in one place, so setup instructions stay consistent.
From the repository root:
python src/lib/installation.pyThis project now has a local HTTP server with the same server-side calculations used in Vercel.
From the repository root:
npm run devOpen http://localhost:3000.
The local server provides:
- Static file hosting for the project
- API route
GET /api/site-context - Server-side calculation for relative paths, breadcrumb parts and favicon resolution
If you need to test without server-side context calculation:
npm run dev:offlineIn this mode, the server still hosts static files, but GET /api/site-context returns 503 on purpose so the frontend uses the local fallback context.
You can also force offline mode in the browser (without restarting the server):
- Add
?offline=1to the page URL, or - Run
setOfflineContextMode(true)in the browser console.
To disable the browser-level override, run setOfflineContextMode(false).
The route api/site-context.js runs as a Vercel Serverless Function.
The frontend requests /api/site-context during initialization, so path and favicon calculations are resolved on the server in production.