feat: added notification system with toasts #160

This commit is contained in:
2024-09-11 15:04:40 +02:00
parent b7cda2db35
commit 0e186940cc
5 changed files with 62 additions and 3 deletions

View File

@@ -78,6 +78,7 @@ func HandleWorkoutNewComp(db *sql.DB) http.HandlerFunc {
Reps: r.FormValue("reps"),
}
w.Header().Set("HX-Trigger", `{"toast": "none|Workout added"}`)
workout.WorkoutItemComp(wo, true).Render(r.Context(), w)
}
}