This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2016-01-04
Channels
- # admin-announcements (15)
- # aws (1)
- # beginners (5)
- # boot (328)
- # cider (5)
- # cljsjs (7)
- # cljsrn (12)
- # clojure (100)
- # clojure-art (3)
- # clojure-austin (1)
- # clojure-chicago (1)
- # clojure-russia (19)
- # clojurecup (2)
- # clojured (2)
- # clojurescript (34)
- # cursive (10)
- # datavis (33)
- # datomic (9)
- # devcards (21)
- # editors-rus (1)
- # events (1)
- # hoplon (42)
- # jobs (5)
- # ldnclj (38)
- # mount (39)
- # om (140)
- # re-frame (26)
- # reagent (25)
- # spacemacs (1)
- # specter (3)
- # vim (1)
hey all - i’m trying to include some react components i built into a cljs project. i’ve specified the foreign-libs but i’m having some issues. i built the react components with webpack with react listed as an external so as to not bundle in multiple copies of react. when i require the components from my cljs project it complains that react isn’t defined even though i’m using om and should have react in my project. what’s the right way to declare that dependency?
https://github.com/crocket/cljs-npm-template is a leiningen template for developing nodejs programs and npm executables in clojurescript. It became stable yesterday.
@yaniv: om brings in react via the cljsjs package, so this should solve your issue:
:foreign-libs
[{:file "resources/js/mywebpackstuff.js"
:provides ["my.stuff"]
:requires ["cljsjs.react"]}]
thanks @cascada-io i tried that at one point. i’ll put that back. I solved it in the short term by bundling everything including react with the components. however i’m getting undefined when trying to log the components so it’s not importing right
@yaniv: https://github.com/glenjamin/cljs-webpack-deps is an example i’m working on for what you describe - it’ll be part of a blog post at some point, but at the mo it’s just some example code
In the absence of extend, does anyone see any problems with clobbering over a default impl-method with specify! ? This seems like a great pattern but I have not seen it
thanks @glenjamin!
When I'm trying too (apply .foo js/bar [...])
it gives me Uncaught SyntaxError: Unexpected token .
Should I appeal to native JS's apply or what?
at least I don't see an error. will test the whole thing in a moment, thanks @jr !
greetings, gentlemen. which the largest public single-/multiple-page app written in you know of?
I need an actual UI, not the code. Like proof of "there are huge UIs build with out there, look: ..."
@misha: I've built a user facing app for schools, but it's behind a login, because it's a paid service
@misha: here it is https://vimeo.com/130967281
it's basically a crud app that stores text (questions and answers) and uploads for several roles: admin, teachers and students. The idea is that admin and teachers can create questions that students have to answer and/or upload a file with it and also teacher can track progress
it could have been built with Ruby on Rails or whatever, but I chose Clojure. The single page aspect wasn't necessary per se, but it seemed much better to me doing it with Reagent than jquery/old fashion style