print object added to clog-obj

This commit is contained in:
David Botton 2024-07-15 19:32:28 -04:00
parent 0bbbcc292e
commit 17281c97b3
2 changed files with 10 additions and 1 deletions

View file

@ -44,6 +44,15 @@ See macro with-connection-cache.")
(:documentation "CLOG objects (clog-obj) encapsulate the connection between
lisp and an HTML DOM element."))
;;;;;;;;;;;;;;;;;;
;; print-object ;;
;;;;;;;;;;;;;;;;;;
(defmethod print-object ((obj clog-obj) stream)
(print-unreadable-object (obj stream :type t)
(with-slots (connection-id html-id) obj
(format stream "connection-id: ~a html-id: ~a" connection-id html-id))))
;;;;;;;;;;;;;;;;;;;
;; create-parent ;;
;;;;;;;;;;;;;;;;;;;

View file

@ -110,7 +110,7 @@ set (logging to browser console) in the default debug.html boot-file.
clog-web and clog-gui are initialized and if use-clog-debugger it set to
true it is initialized and this repl window used as default clog debug display
and debugger display for clog events."
(unless *clog-running*
(unless clog-connection:*clog-running*
(initialize nil :boot-file boot-file :port port))
(set-on-new-window (lambda (body)
(debug-mode body)