feat: Introduce application version display in the frontend footer, showing both frontend and backend versions with integrated build arguments.
All checks were successful
Release and Build Docker Images / release-and-build (push) Successful in 1m29s

This commit is contained in:
almazlar
2026-02-21 10:34:08 +03:00
parent bbd3beb22a
commit 37ae9dbe53
7 changed files with 91 additions and 4 deletions

View File

@@ -33,3 +33,11 @@ export const deleteTodo = async (id) => {
if (!response.ok) throw new Error('Failed to delete todo');
return true;
};
export const getVersion = async () => {
// Use the origin to ensure it accesses the /api/version correctly regardless of environment
const VERSION_URL = BASE_URL.replace('/todos', '/version');
const response = await fetch(VERSION_URL);
if (!response.ok) throw new Error('Failed to fetch version');
return response.json();
};