Testar render_template() för att få över information till klienter

This commit is contained in:
Joakim Persson
2024-07-24 17:26:57 +02:00
parent ce5532e9a6
commit 7c9d20896e
+15
View File
@@ -0,0 +1,15 @@
<!DOCTYPE html>
<html>
<head>
<title>Frontend</title>
</head>
<body>
<script>
const apiEndpoint = '<%= api_endpoint %>'; // Templating syntax (Jinja2)
console.log("API Endpoint:", apiEndpoint);
// Use apiEndpoint in your frontend code...
</script>
</body>
</html>