From 60ecb901b2e4ecd9d42451f4794875b7e8cbffc1 Mon Sep 17 00:00:00 2001 From: Andrey Antukh Date: Fri, 13 Feb 2026 08:21:37 +0100 Subject: [PATCH] :sparkles: Make the obj/proxy object do not extend js/Object directly --- frontend/src/app/util/object.cljc | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/frontend/src/app/util/object.cljc b/frontend/src/app/util/object.cljc index 723444b4d5..57dc8df4fe 100644 --- a/frontend/src/app/util/object.cljc +++ b/frontend/src/app/util/object.cljc @@ -425,6 +425,13 @@ (let [o (get o type-symbol)] (= o t)))) +#?(:cljs + (def Proxy + (app.util.object/class + :name "Proxy" + :extends js/Object + :constructor (constantly nil)))) + (defmacro reify "A domain specific variation of reify that creates anonymous objects on demand with the ability to assign protocol implementations and @@ -442,7 +449,7 @@ obj-sym (gensym "obj-")] - `(let [~obj-sym (cljs.core/js-obj) + `(let [~obj-sym (new Proxy) ~f-sym (fn [] ~type-name)] (add-properties! ~obj-sym {:name ~'js/Symbol.toStringTag