I suspect that the problem is that the library I'm looking to fetch does 
not actually export anything. It only defines a polyfill. If there's any 
way to make that work I'd like to know.

Christian

fredag 26. mai 2017 10.59.20 UTC+2 skrev Christian Johansen følgende:
>
> I'm in need of an EventSource polyfill for my app to work in IE/Edge. So I 
> figured I'd take a look at the new npm support. I can get the left-pad 
> example from this post to work: 
> https://anmonteiro.com/2017/03/requiring-node-js-modules-from-clojurescript-namespaces/
>
> However, trying to build with the module I actually need does not work:
>
> (ns test.ns
>   (:require event-source-polyfill))
>
> Build with:
>
> (b/build "test/ns.cljs"
>                {:optimizations :none
>                 :main 'test.ns
>                 :npm-deps {:event-source-polyfill "0.0.9"}
>                 :output-to "test.js"})
>
> Fails with:
>
> ExceptionInfo No such namespace: event-source-polyfill, could not locate 
> event_source_polyfill.cljs, event_source_polyfill.cljc, or Closure 
> namespace "event-source-polyfill"
>
> I can `require` the module from a Node repl just fine, so there's nothing 
> obviously wrong with the module.
>
> Any ideas?
>
> Christian
>

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to