ldnclj

Find us on #clojure-uk
agile_geek 2016-01-19T07:34:21.001181Z

Morn'

agile_geek 2016-01-19T07:38:47.001182Z

Much simpler question than @mccraigmccraig's but how are ppl managing cljsbuild in lein so that figwheel is on for dev but not for prod builds? I tried specifying default build options in :cljsbuild at top level and then activating figwheel only in dev profile but this doesn't work because figwheel doesn't honour profile merging. So ended up having to specify :figwheel true at top level which means it's 'on' all the time. See https://github.com/ldnclj/meetdown/blob/reagent-spike-merge/project.clj

2016-01-19T07:41:13.001184Z

@mccraigmccraig: we solved a similar problem by using one uber-repo and adding the common stuff to sources in each artefact project (e.g. “../model/src”)

thomas 2016-01-19T09:07:46.001185Z

morning

benedek 2016-01-19T09:21:14.001186Z

@agile_geek I have something like

:cljsbuild

  {:builds

   {:dev

    {:source-paths ["src/cljs"]

     :figwheel true

     :compiler {:output-to "resources/public/js/app.js"

                :output-dir "resources/public/js/out"

                :main "meta-insight.core"

                :asset-path "/js/out"

                :recompile-dependents true}}

    :prod

    {:source-paths ["src/cljs"]

     :compiler {:output-to "resources/public/js/app.js"

                :output-dir "resources/public/js/compiled/out"

                :asset-path "/js/compiled/out"

                :optimizations :simple

                :main "meta-insight.core"}

benedek 2016-01-19T09:21:51.001187Z

And then figwheel only added in the dev profile

agile_geek 2016-01-19T09:22:52.001188Z

@benedek: how do you ensure your server serves the asset for dev build for dev profile and prod for prod?

agile_geek 2016-01-19T09:23:37.001189Z

i.e. doesn't your server need to point to /compiled/out for only prod builds?

benedek 2016-01-19T09:26:34.001190Z

Asset path is different for the two diff cljs build env

benedek 2016-01-19T09:26:49.001191Z

Or I am not sure what u mean

agile_geek 2016-01-19T09:33:53.001192Z

I saw that. Does the page from the server just load "resources/public/js/app.js" and that picks up appropriate assets?

benedek 2016-01-19T09:37:28.001193Z

Yup I guess

agile_geek 2016-01-19T09:38:33.001195Z

😁

benedek 2016-01-19T09:38:35.001196Z

Did I say that out loud?

🙉 1
benedek 2016-01-19T09:45:35.001197Z

I have <script src="/js/app.js"></script> in my index.html so I guess again it should

agile_geek 2016-01-19T09:50:07.001198Z

Thx @benedek I'll try that. Do you use the new way of connecting to figwheel via nRepl (i.e. lein repl then (use 'figwheel-sidecar.repl-api) then (start-figwheel!) and (cljs-repl) rather than lein figwheel)?

agile_geek 2016-01-19T09:50:40.001199Z

BTW more importantly...what is up with Twitter?

agile_geek 2016-01-19T09:51:17.001200Z

I'm desperately trying to push my opinion down the throats of my followers and the systems overloaded.

benedek 2016-01-19T09:52:22.001202Z

I use repl in cider and then start figwheel from there

benedek 2016-01-19T09:52:34.001203Z

Really awesome dev experience actually

agile_geek 2016-01-19T09:52:54.001204Z

Yep that's what I'm doing

benedek 2016-01-19T10:00:48.001205Z

Yes so the former

agile_geek 2016-01-19T16:00:39.001206Z

Has anyone tried DevCards? I like the look of it but I have spent 30 mins trying to get anything to render within an existing app and can't. I get frustrated with the amount of knowledge required to simply get anything working in the cljs world sometimes.

2016-01-19T16:13:22.001207Z

you should try the js world :simple_smile:

meow 2016-01-19T22:51:21.001208Z

I like devcards

meow 2016-01-19T22:52:49.001209Z

started using it here, but haven't touched it in many weeks: https://github.com/decomplect/ive

meow 2016-01-19T22:54:11.001211Z

dragon fractals, for example: https://github.com/decomplect/ive/blob/master/src/ive/ergo/lindenmayer.cljs