Fork me on GitHub
#figwheel-main
<
2018-10-16
>
pesterhazy12:10:01

I'm getting this error when requiring a global export:

Use of undeclared Var my.app.router.router5/ladida

   2    (:require [goog.object :as gobj]
   3              [reagent.core :as r]
   4              ["router5" :as router5]
   5              ["router5-plugins-browser" :as ladida]))
   6
   7  (js/console.warn "ladida is" ladida)

pesterhazy12:10:54

but ladida is declared in the ns decl just above it

pesterhazy12:10:43

hmm I think it's this

pesterhazy12:10:57

specified like this it works

:global-exports {react React
                                  react-dom ReactDOM
                                  create-react-class createReactClass
                                  router5-plugins-browser "router5/plugins/browser"}

pesterhazy12:10:17

but specified like this, it doesn't:

:global-exports {react React
                                  react-dom ReactDOM
                                  create-react-class createReactClass
                                  "router5-plugins-browser" "router5/plugins/browser"}

pesterhazy12:10:45

I also seem to need to clean target/ to make changes take effect (sometimes?)

Toby13:10:16

@bhauman fwiw, I’m able to demonstrate that it is not a connectivity problem. The socket can be successfully opened and a response from figwheel is received. For some reason I can’t ascertain, the browser code (or figwheel) then closes the connection.

Toby16:10:59

Doesn’t work outside of docker either, as it happens

Toby16:10:40

Is the websocket server (or the client) performing cross-origin checks on this socket?

Toby16:10:57

No, that’s not it. It crashes even if I just load the dev page from the same hostname.

kwladyka17:10:05

@bhauman watching outside project directory works. Great, it is very useful:beers:

👍 4