This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-03-20
Channels
- # arachne (4)
- # bangalore-clj (1)
- # beginners (38)
- # boot (182)
- # cider (21)
- # cljs-dev (9)
- # clojars (5)
- # clojure (229)
- # clojure-austin (1)
- # clojure-berlin (1)
- # clojure-czech (3)
- # clojure-dusseldorf (3)
- # clojure-ireland (5)
- # clojure-italy (4)
- # clojure-russia (33)
- # clojure-spec (73)
- # clojure-taiwan (6)
- # clojure-uk (22)
- # clojure-ukraine (1)
- # clojurescript (80)
- # core-async (26)
- # cursive (3)
- # datascript (20)
- # datomic (9)
- # defnpodcast (8)
- # editors (4)
- # emacs (7)
- # garden (41)
- # hoplon (2)
- # java (1)
- # lambdaisland (2)
- # lein-figwheel (1)
- # leiningen (5)
- # luminus (4)
- # lumo (36)
- # off-topic (4)
- # om (21)
- # onyx (1)
- # pedestal (33)
- # re-frame (33)
- # ring-swagger (70)
- # spacemacs (26)
- # specter (7)
- # sql (6)
- # timbre (2)
- # untangled (12)
- # vim (3)
- # yada (1)
I had an issue with goog not being defined when using :optimizations none, but not with it turned on. I sure would like to be able to turn off opts b/c it is noticeably slower to rebuild.
@mattsfrey if you put the jsloader into your :require
it is guaranteed to be there
if it is not in there you are relying on someone else having required it (ie. figwheel), so it may be lost if figwheel is no longer required (ie. optimizes builds)
@dpurrington I think CLJS still requires that you manually include goog/base.js
for :none
unless you are using :main
I've not manually included something before. Where would I do that? Does that happen in my project file?
https://github.com/clojure/clojurescript/wiki/Quick-Start#using-clojurescript-on-a-web-page
ah. I'm in a nodejs context.
So I get the error on build.
dyu mean as a cljs ompiler option @hit023 ? if so, it enables source-map generation - https://github.com/clojure/clojurescript/wiki/Compiler-Options#source-map
hi guys, have a question about the function js->clj, I have read the source of that why does it just support transform plain js object?
@thheller it's in the require, but is showing up undefined when built with optimizations: advanced
Hey everyone, I’m new to Clojure/ClojureScript so I’m sorry if this glaringly obvious. I can’t seem to figure out this seemingly trivial issue:
The console output for this is:
This is a re-frame subscription, but I don’t think my issue is re-frame specific. I’m expecting find-sequence to return the correct sequence record based on the id argument, but I keep on getting nil.
It could be that your seq-id
is a string, and the ids in the sequences might be numbers
You know, I bet that’s it
@danieleneal That was it! I’m using https://github.com/gf3/secretary for routing and it didn’t occur to me that all params would be strings.
Thanks!
Doesn’t help that println doesn’t quote strings without spaces 😛
ha! yeah! This might be useful
http://stackoverflow.com/questions/21136766/clojure-printing-functions-pr-vs-print
I just came across it - I've always been a bit haphazard over whether I use println
or prn
for debugging statements
(prn)
produces things that can be read back in so (prn "2")
=> "2"
where (println "2")
=> 2
Ah nice, thanks for that tip
Or does it? This is weird: context = {:id "2"} seq-id = 2
@gklijs It’s all good now, @danieleneal pointed the issue (see above)
I need to perform n ajax requests simultaneously and then 1 subsequent ajax request when all of the prior n have completed
trying to figure out the best way to do it in cljs using only cljs (and core/async probably?)
@samueldev so core.async
would also be my go-to for what you’re trying to do. Do N requests, put all their responses in a core.async channel, perform the last request when you’ve consumed everything from the channel
(and when there aren’t any in-flight requests)
Should a ClojureScript library use cljsbuild?
I have a library that defines (ns clientcommon.conf)
and when I try to use it on another app (after installing it locally with lein install), I get this error: Caused by: clojure.lang.ExceptionInfo: No such namespace: clientcommon.conf, could not locate clientcommon/conf.cljs, clientcommon/conf.cljc, or Closure namespace "clientcommon.conf" in file C:\Users\pupeno\Documents\Dashman\configurator\src\app\configurator\sites.cljs {:tag :cljs/analysis-error}
Any ideas why?
@samueldev is promesa off the table?
@johanatan I had never heard of it until now, doing a quick search 🙂
@samueldev it's the way i'd go. nicer abstractions than core.async
@pupeno did you check the contents of the generated .jar
for your lib? if the file isn't in there in the correct path it won't be found
@thheller yes, I did, and the files were there but there was a stupidly embarrassing typo. 😳
hello!
I'd love to ask this channel a favor
I'm doing research for a re-frame course (I teach Clojure and ClojureScript at http://PurelyFunctional.tv)
Please fill out this survey about re-frame. It will take 2 minutes: https://purelyfunctional.tv/re-frame-survey/
it will help me make sure the course addresses your needs
planck is more usable out-of-the-box (thanks to a custom api that tries to be similar to jvm clojure for files and shell), lumo is easier to get things done with (thanks to using node stdlib, and npm installed deps)
I'm trying to use clojure.data.xml
with a cljs/nodejs project. I'm kinda stuck getting emit-str
to work (the doc says it should on cljs). This is the error I'm getting. Does anyone know how to fix/workaround this?
org.mozilla.javascript.EcmaError: ReferenceError: "XMLSerializer" is not defined. (rhino.clj#41)
@johanatan , @noisesmith : Am I using the right term? I thought "insta repl" means an editor where you type clj code and it's evalauted as you type; whereas it seems like to me, insta repl -= instantly starting repl.
@noisesmith @qqq also, lumo starts up more quickly. planck is more mature however (as you mentioned)
@qqq not sure if there is any std use of the term "insta". they're just REPLs to me
@qqq You are probably looking for "interactive programming" - I'm not sure what the standard terms are either. Here's what I use (CIDER - https://cider.readthedocs.io/en/latest/interactive_programming/)
@sankara CIDER is nice but i've found it's less reliable in CLJS land than plain CLJ. hence, i most often just copy paste from an editor into a CMD SHELL-based REPL
[also, my webapp itself uses figwheel which pops open a REPL automatically; once again somewhat detached from the editor]
another option that is sometimes more elegant than copy/paste is load-file
I'm looking for osmething like: http://oakes.github.io/paren-soup/ -- but a bit more mature
for example, in the 0 1 2 3 4 part, add a "5 6 7", don't even bother to hit enter, and see what happens
@qqq that looks like more of a "literate programming" tool somewhat along the lines of iPython notebook
@qqq I know this isn’t a popular opinion, but I’d rather not use such tooling at all rather than deal with buggy tooling that sends me on wild goose chases for bugs, and I have yet to try anything of that type that doesn’t break on me in weird ways.
@qqq not sure if there are any std solutions for that in CLJ/CLJS land (probably several competing ones w/ no clear winner)
Jupyter claims to support Clojure notebooks: https://jupyter.org/