This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-01-19
Channels
- # beginners (34)
- # boot (111)
- # cider (37)
- # clara (57)
- # cljsjs (1)
- # cljsrn (22)
- # clojure (156)
- # clojure-austin (2)
- # clojure-mke (7)
- # clojure-russia (9)
- # clojure-spec (221)
- # clojure-uk (47)
- # clojurescript (42)
- # code-reviews (4)
- # community-development (9)
- # core-async (3)
- # cursive (50)
- # datomic (81)
- # emacs (12)
- # events (5)
- # hoplon (1)
- # jobs (2)
- # lein-figwheel (4)
- # leiningen (1)
- # luminus (3)
- # mount (2)
- # off-topic (1)
- # om (94)
- # om-next (3)
- # onyx (33)
- # re-frame (23)
- # reagent (41)
- # remote-jobs (9)
- # rum (30)
- # slack-help (2)
- # specter (1)
- # untangled (20)
- # yada (17)
have asked a same question before, but still no idea for now.
If I want to introduce a third party library which has a lot of .js
.
for example:
.
├── Editor
│ ├── MultiDecorator.js
│ ├── __test__
│ │ ├── MultiDecorator.js
│ │ └── index.js
│ ├── createCompositeDecorator.js
│ ├── defaultKeyBindingPlugin.js
│ ├── index.js
│ ├── moveSelectionToEnd.js
│ └── proxies.js
├── index.js
├── modifiers
│ ├── moveToEndOfSelectedBlock.js
│ └── moveToStartOfSelectedBlock.js
└── utils
├── composeDecorators.js
├── createCompositeDecorator.js
├── createEditorStateWithText.js
└── moveSelectionToEnd.js
I need to add them all into :foreign-libs
and require one by one?@doglooksgood probably easier if you bundle everything with Webpack for example, and use that single bundle as a foreign lib
is there any reason you can't do that?
I just wondering if there's a simpler way to do this. Maybe I should bundle all js libraries into one file with webpack?
I've got the cheekiest bug. It doesn't work but as soon as I put in some println
's is goes away haha.
@grounded_sage sounds like something lazy
being forced by println
@grounded_sage it's a very common Clojure(script) gotcha
Apparently it has to do with a macro expansion. I will get a handle of this stuff one day!
How far away are we from a new ClojureScript release? I’m looking forward to data readers support. 🙂
With that not being available yet: is there another way to add custom tagged literals in CLJS?
you might want to take a look at https://lambdaisland.com
Lambda Island is a product of a lone developer, with great tutorials. Paying for it is a good thing IMO
Is anyone here coding in a docker environment and if so. What steps did you take to get your environment to push changes to your browser?
@lorenzoi I watch a lot of conference videos relating to CLJS. There are a couple Cognitect webinars as well
@petr haven’t done this myself, but some workmates did. we did this both with boot with boot-reload and leiningen with figwheel.
problems to be solved were something related to file watcher strategy (the default wasn’t working with docker, but there was another option that did) and forwarding the port to the host (with -pN:N
?) so it’s accessible by the browser
I just watched one of the free lamda island videos and that definitely looks like it's worth the money
http://purelyfunctional.tv is good as well
If I have the following function with a precondition assertion:
(defn- total-pages [total per-page]
{:pre [(<= 0 total) (pos? per-page)]}
(-> (if (zero? total) 1 total)
(/ per-page)
(Math/ceil)
(int)))
How would I write a test for the precondition assertion exception?@petr The major things you need are a docker image with lein and/or boot (there are several on docker hub), a port mapping between your app's ports (and any repl/dev ports) and your host network ports, as @rafaelzlisboa mentioned, and a volume mount of your project into the container. All those things can be set up pretty easily in a docker-compose file so you don't have to type everything all the time.
@ezmiller77 (is (thrown? AssertionError ... ))
Beginner to CLJS here, quick question: find myself needing to access a thing in the REPL (a function that is partially applied with some derived stuff), but its defined in the main fn. Anyway to expose that to the REPL without needing to set it to a var in the ns scope?
Also a beginner but from what I understand you need to have some sort of reference to it.
Possibly using a breakpoint https://github.com/shaunlebron/How-To-Debug-CLJS#breakpoints