Closed grinderrz closed 6 years ago
This was fixed in 0.5.2.
Experiencing this on 0.5.2 now. As I understand, there was fixed a similar issue #117 with .loadMany Call to .load is still here
I am also having a similar error, and can confirm that the following from client.cljs seems to be the trouble code.
; Thanks, lein-figwheel & lively!
(defn patch-goog-base! []
(set! (.-provide js/goog) (.-exportPath_ js/goog))
(set! (.-CLOSURE_IMPORT_SCRIPT (.-global js/goog)) (fn [file]
(when (.inHtmlDocument_ js/goog)
(jsloader/load file)))))
Edited to provide my error:
#object[TypeError TypeError: goog.net.jsloader.load is not a function]
TypeError: goog.net.jsloader.load is not a function
at adzerk.boot_reload.client.patch_goog_base_BANG_.goog.global.CLOSURE_IMPORT_SCRIPT (http://localhost:3000/js/main.out/adzerk/boot_reload/client.js:18:26)
at Object.goog.importScript_ (http://localhost:3000/js/main.out/goog/base.js:951:9)
at Object.goog.writeScripts_ (http://localhost:3000/js/main.out/goog/base.js:1394:16)
at Object.goog.require [as require__] (http://localhost:3000/js/main.out/goog/base.js:706:14)
at Object.clojure.browser.repl.bootstrap.goog.require (http://localhost:3000/js/main.out/clojure/browser/repl.js:295:16)
Does this happen when using repl?
Yes. I'm working through modern-cljs, and the error occurs with this call:
cljs.user=> (require '[modern-cljs.login :as l] :reload)
FWIW this seemed to happen to me when I tried directly running client/connect
at the top level of an ns that was in my :preloads
. When I moved it into my window.onload function, the problem went away. Not sure what to make of that, but hopefully it helps.
Also experiencing this
https://github.com/adzerk-oss/boot-reload/pull/122 has been merged and released in 0.6.0
Which results in
According this commit, one should use .safeLoad instead.