This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2015-08-20
Channels
- # admin-announcements (26)
- # beginners (1)
- # boot (157)
- # cider (46)
- # clojure (52)
- # clojure-italy (19)
- # clojure-japan (31)
- # clojure-russia (61)
- # clojure-sg (3)
- # clojurescript (65)
- # clojurex (7)
- # clojutre (8)
- # datascript (15)
- # editors (19)
- # emacs (9)
- # funcool (13)
- # hoplon (74)
- # ldnclj (13)
- # liberator (20)
- # off-topic (70)
- # om (5)
- # onyx (1)
- # re-frame (5)
- # reagent (20)
- # testing (23)
@bostonaholic: Looks like OS X 10.8 Mountain Lion will be supportable by Planck and perhaps 10.7 Lion as well.
so I want to make a cljsjs package for https://github.com/callemall/material-ui, but there's no single file to build externs from, unlike react-bootstrap, which has the https://github.com/react-bootstrap/react-bootstrap-bower project. when I try to build material-ui using webpack, it bakes react into the compiled JS, which is not what I want at all. any ideas?
mfikes: what set of the core libary does planck have access to atm? for example does slurp work?
anyone using figwheel in the their normal clojure REPL, i.e. perhaps as a component?
I have this issue with :optimization options. I get the following cljs->js. cljs: (defn start-upgrading [] (js/setInterval #(.upgradeDom js/componentHandler) 100)) :optimization :whitespace yields: setInterval((function (){ return componentHandler.upgradeDom(); }),(100)); :optimization :advanced yields: setInterval((function (){ return http://componentHandler.pa(); }),(100)); Any ideas?
closure is allowed to rename property names with advanced compilation
@jonpither: yes, not as a component, but as described here: https://github.com/bhauman/lein-figwheel/wiki/Running-figwheel-in-a-Cursive-Clojure-REPL
is upgradeDom
defined in cljs, or in js?
in js
But closure should not rename the standard library though right? Though Cursive also didn't seem to locate componentHandler.. it tells me it is undefined.
what do you mean by the 'standard library'? isn't this part of material design, not closure or the various browser standard apis?
Sorry, I assumed it was a simple standard javascript function, but you are right, it's a part of mdl.
so :advanced compilation also runs over the mdl library and somehow breaks it by renaming properties?
hey @yogthos, I like your reagent-forms library. have you got any examples including validation that I can borrow from maybe?
@not-much-io: closure will rename the files it knows about. Are you feeding your mdl library to it?
@borkdude: hmm the easiest would be to use something like bouncer and hook it in as an event, but I don't have an example handy
@yogthos: I thought so, just call bouncer in the last function you pass to bind-fields, or use it in add-watch
@not-much-io: I'm guessing you're including mdl as js (not through closure), and trying to call it from cljs with advanced compilation?
@bensu I am not sure if I am, here is the place I included in the project that has the problem.
@underplank: There are things in clojure.core
,
, and clojure.java.shell
that have imitations in planck.core
,
, and planck.shell
. And planck.core/slurp
is available.
@mcgivernsa: I guess I am? Sry I'm rather new to clojurescript. How should I include mdl then?
@bensu link: https://github.com/not-much-io/papyri-demo/blob/master/src/clj/papyri_demo/handler.clj
@mcgivernsa: @bensu : I'll figure it out based on this: http://lukevanderhart.com/2011/09/30/using-javascript-and-clojurescript.html I just didn't know what I didn't know
OK cool, so you need an externs file?
So as I understood it for using advanced compilation I'd need to use the following style for including js files: (closure/build "src/cljs" {:optimizations :advanced :libs ["libs/my-gclosure-library.js"] <-- This way :output-to "helloworld.js"})
@mcgivernsa: I'll read up, thanks for the help.
@not-much-io: unfortunately the externs story is not easy. Is your library in cljs? https://github.com/cljsjs/packages
It's not on cljsjs, already checked.
@bensu Is it really that bad?
@bensu Is it neccesary to jump through these hoops if I just don't use advanced compilation?
@bensu I'm just getting started, so I'd rather not be sidetracked by something like this yet. I'll build something and then try to get advanced compilation up and running. Main thing is I now know this can happen.
yeah, advanced compilation is much more aggressive
@not-much-io: good call. come back then. In any case, you'll need to understand a little bit of what goes on in :advanced
and how do externs help. Once you understand the concepts, writing externs for what you need is hard.
@yogthos: the event function in reagent-forms accepts an id and a value. why is the id a lazy seq?
If I recall correctly it's actually a path, if you have element with id person.name it gets translated into [:person :name]
So compiler option :main
doesn't really make sense with :modules
right? Is it just ignored?
@dnolen: Do you have any opinions on how putting userscript/Greasemonkey headers in front of compiled JS files should work? I found https://groups.google.com/forum/?fromgroups=#!topic/clojurescript/_qViDrdu30U, but I know a lot has changed in Clojurescript since that happened; specifically ISTR you’re not actively recommending cljsbuild anymore.
@rauh: cljs.build.api/inputs
@juhoteperi: Ahh, thanks!
Can I mix some simple JQuery with a SPA using, say, reagent, or will bad things happen? There’s a lib I’d rather avoid porting if I can.
You should be able to use jQuery with React so long as the jQuery changes and react changes are separate.
@cfleming: yup, I've done this
and now porting some of the jQuery to reagent
like, we're using zurb foundation and some of its javascript components use jQuery
and we've extracted our own adapters to make it work more smoothly so there isn't quite as much jQuery, just in the adapters
something we're working to OSS
@bostonaholic: @spinningtopsofdoom: Awesome, thanks.
I may be able to just port the input handling and call the JS functions that it calls directly.