This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2022-04-14
Channels
- # aleph (2)
- # announcements (11)
- # aws (4)
- # babashka (42)
- # babashka-sci-dev (81)
- # beginners (90)
- # biff (2)
- # calva (40)
- # cider (16)
- # clj-kondo (26)
- # clj-on-windows (1)
- # cljdoc (4)
- # cljfx (1)
- # cljsrn (2)
- # clojure (92)
- # clojure-austin (2)
- # clojure-europe (23)
- # clojure-nl (5)
- # clojure-uk (3)
- # clojured (3)
- # clojurescript (19)
- # community-development (3)
- # conjure (1)
- # cursive (4)
- # datalevin (3)
- # datomic (5)
- # emacs (13)
- # events (1)
- # fulcro (26)
- # graphql (1)
- # hugsql (15)
- # introduce-yourself (5)
- # leiningen (1)
- # lsp (29)
- # minecraft (19)
- # music (1)
- # off-topic (36)
- # pathom (12)
- # podcasts (2)
- # portal (8)
- # re-frame (12)
- # reagent (11)
- # rewrite-clj (4)
- # shadow-cljs (56)
- # spacemacs (2)
- # vim (12)
- # windows (3)
- # xtdb (43)
Hi! On NodeJS I'm trying to read and process huge backup files one S-Exp at the time without getting out of memory. So I guess I have to somehow implement IPushbackReader on Readable streams. Did somebody ever do something similar by chance?
Not sure if this helps, but JS has array buffers, which you can use to explicitly allocate and avoid GC. As always the best documentation is on MDN: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer
cljs makes use of this: https://github.com/clojure/tools.reader which looks like it should work on node.js: https://github.com/clojure/tools.reader/blob/master/src/main/cljs/cljs/tools/reader/reader_types.cljs
I have an async function in js, which is called with await foo()
. How can I call foo in cljs?
yep, all of the google closure library is available: https://google.github.io/closure-library/api/goog.html which has dom helpers https://google.github.io/closure-library/api/goog.dom.html sources: https://github.com/google/closure-library/blob/master/closure/goog/dom/dom.js

I need to synchroneously wait for the result of a go block (due to a cljs-http call), is there a way to do that ?
Huh, is there really no blocking get in core.async?
I would have expected it semantically to mean “don't move on until this form is done”
Well, you can fire off some code as a reaction to a result of a go block.
Only that result->reaction part will be synchronous. But the whole app will be async - there will be other code running. That's why you can't just pass a result of a go
block into a function - you have to restructure your code in such a way so that it works correctly in an inherently async environment.