feat: wire up / index handler replacing /hello

This commit is contained in:
2026-06-20 16:59:19 -04:00
parent 94c310a0b3
commit 794ef3ffc9
+6 -4
View File
@@ -227,10 +227,12 @@ Set by test harnesses that only need the model functions.")
;; --- handlers --------------------------------------------------------- ;; --- handlers ---------------------------------------------------------
(defservlet hello text/html () (defservlet index text/html ()
(insert (spine-render "hello.mustache" (let ((books (spine-books)))
(ht ("title" "Spine") (if books
("message" "Hello from Emacs."))))) (insert (spine-render-index books
(ht-get (ht-from-query-string (httpd-query-string)) "id")))
(insert (spine-render-empty-state)))))
;; --- start ------------------------------------------------------------ ;; --- start ------------------------------------------------------------
(unless spine-skip-server-start (unless spine-skip-server-start