Improve
This commit is contained in:
parent
0441d03206
commit
21c2d8aa99
18 changed files with 130 additions and 117 deletions
src/routes
|
@ -1,8 +1,7 @@
|
|||
(uiop:define-package #:hp/routes/index
|
||||
(defpackage #:hp/routes/index
|
||||
(:use #:cl)
|
||||
(:local-nicknames (#:pi #:piccolo))
|
||||
(:local-nicknames (#:jg #:jingle))
|
||||
(:local-nicknames (#:cmp #:hp/components/*))
|
||||
(:local-nicknames (#:view #:hp/view))
|
||||
(:export #:on-get))
|
||||
(in-package #:hp/routes/index)
|
||||
|
||||
|
@ -10,11 +9,13 @@
|
|||
|
||||
(pi:define-element page ()
|
||||
(pi:h
|
||||
(div)))
|
||||
(section
|
||||
(h1 "Hello, World!")
|
||||
(a :href "/about" :hx-boost "true"
|
||||
"About"))))
|
||||
|
||||
;;; Controller
|
||||
|
||||
(defun on-get (params)
|
||||
(declare (ignore params))
|
||||
(jg:with-html-response
|
||||
(pi:element-string (page))))
|
||||
(view:render-page (page)))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue