This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-07-15
Channels
- # aleph (9)
- # announcements (6)
- # beginners (42)
- # calva (4)
- # cider (9)
- # clara (2)
- # clj-kondo (1)
- # cljdoc (108)
- # cljs-dev (10)
- # clojure (25)
- # clojure-brasil (1)
- # clojure-chicago (1)
- # clojure-europe (4)
- # clojure-italy (42)
- # clojure-nl (14)
- # clojure-uk (66)
- # clojurebridge (3)
- # clojurescript (23)
- # clojutre (2)
- # community-development (1)
- # cursive (2)
- # datomic (4)
- # figwheel-main (21)
- # fulcro (23)
- # jobs-discuss (1)
- # kaocha (1)
- # off-topic (10)
- # pedestal (4)
- # reitit (2)
- # shadow-cljs (41)
- # spacemacs (7)
- # sql (20)
- # xtdb (3)
For web workers to make sense, your distributed job needs to be very compute heavy, otherwise you'll waste all your time "over the wire"
But there's other tricks with Offscreen Canvas and SharedArrayBuffers that allow for shared memory access in some constrained situations
Hm, I have a file called stats_and_items.cljs
, and when I compile to stats_and_items.js
I find this at the end of that file:
//# sourceMappingURL=stats_and_items.js.map
and_items.js.map
And then the browser complains that there is nothing called and_items
. What is going on? Why is that and_items.js.map
at the bottom of the file?Maybe it's not cljs-devtools, because I have gone back to my old settings of not using them more than what figwheel-main does
@john thanks!
Hey guys , how do you check for page load in clojurescript . I want to add a class to a div after page load.
Is something like this even possible or make sense ? If not , what is the right way of going about it
[:div {:class (when (on page load condition) "class-name")}]
(def loaded? (r/atom false))
(.addEventListener js/document "load" #(reset! loaded? true))
(defn app []
[:div {:class (when @loaded? "class-name")}])
if you are using reagent ^
Cheers @roman01la 🙂
uh oh.. wasn't there a whole debate about whether non-fn's should use "predicate naming convention", for ex. the fn odd?
vs. the above example loaded?
🤓
Good evening 🙂 I’m trying to add an npm dependency to a simple project. Is this the correct way to add the dep?
is the file deps.edn
? :npm-deps
is configuration of clojurescript compiler https://clojurescript.org/reference/compiler-options which you should put together with other compiler options. For figwheel-main it's probably dev.cljs.edn
(https://github.com/bhauman/figwheel-main/blob/master/docs/docs/npm.md#configure-our-clojurescript-build-to-use-libraries-in-the-bundle)
@U60RB7X63 Hi, you are right it was in deps.edn
I managed to spot this the other day and move it into my build file dev.cljs.edn
however I still couldn’t see the node modules being downloaded when restarting the app 😞