Rename render to render-to-string

This commit is contained in:
Akira Tempaku 2024-06-01 22:49:15 +09:00
commit 626fa3fe3e
4 changed files with 39 additions and 29 deletions

View file

@ -16,7 +16,7 @@
#:element-props
#:element-children
#:expand-component
#:render))
#:render-to-string))
(in-package #:hsx/element)
;;;; class definitions
@ -63,9 +63,9 @@
;;;; methods
(defmethod render ((element element) &key minify)
(defmethod render-to-string ((element element) &key pretty)
(with-output-to-string (stream)
(write element :stream stream :pretty (not minify))))
(write element :stream stream :pretty pretty)))
(defmethod print-object ((element tag) stream)
(with-accessors ((type element-type)

View file

@ -6,5 +6,5 @@
#:hsx/hsx)
(:export #:hsx
#:defcomp
#:render))
#:render-to-string))
(in-package :hsx)