fix: restructure env handling for better testing capabillities #181
This commit was merged in pull request #195.
This commit is contained in:
@@ -1,8 +1,6 @@
|
||||
package template
|
||||
|
||||
import "me-fit/utils"
|
||||
|
||||
templ Layout(slot templ.Component, user templ.Component) {
|
||||
templ Layout(slot templ.Component, user templ.Component, environment string) {
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
@@ -11,7 +9,7 @@ templ Layout(slot templ.Component, user templ.Component) {
|
||||
<link rel="icon" href="/static/favicon.svg"/>
|
||||
<link rel="stylesheet" href="/static/css/tailwind.css"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
||||
if utils.Environment == "prod" {
|
||||
if environment == "prod" {
|
||||
<script defer src="https://umami.me-fit.eu/script.js" data-website-id="3c8efb09-44e4-4372-8a1e-c3bc675cd89a"></script>
|
||||
}
|
||||
<script src="/static/js/htmx.min.js"></script>
|
||||
|
||||
Reference in New Issue
Block a user