[ClojureScript] Re: ANN: ClojureScript 1.9.198 - cljs.spec, core ns aliasing, macro inference, :rename, and more!

2016-08-13 Thread Zubair Quraishi
I don't know what you did but upgrading from cljs .89 to .198 on a fairly 
largish app and it seems to run over twice as fast Welldone, whatever it 
was that did it!!! :)


On Friday, August 12, 2016 at 9:50:20 PM UTC+2, David Nolen wrote:
> ClojureScript, the Clojure compiler that emits JavaScript source code.
> 
> 
> README and source code: https://github.com/clojure/clojurescript
> 
> 
> Leiningen dependency information:
> 
> 
>     [org.clojure/clojurescript "1.9.198"]
> 
> 
> This release brings cljs.spec to parity with Clojure
> 1.9.0-alpha10. This release also includes a large number of
> enhancements to the ns form:
> 
> 
> * :refer now features macro inference. There is no longer any need
>   to supply both :refer and :refer-macros in the same :require, the
>   compiler will figure it out.
> 
> 
> * clojure.* namespaces will now automatically be aliased to their
>   ClojureScript equivalents. For example this means that the following
>   is perfectly valid ClojureScript:
> 
> 
>   (ns foo.bar
>     (:require [clojure.spec :refer [fspec]]))
> 
> 
>   This feature and the previous one should significantly reduce reader
>   conditional usage in ns forms.
> 
> 
> * thanks to Antonio Monteiro we now support :rename
> 
> 
> We also have a new feature that is relevant for tooling such as
> Figwheel and cljs-devtools - :preloads. This should now be the
> standard way to inject some bit of side-effecting setup after core but
> before user code (i.e. connecting REPLs to standard ports, etc.).
> 
> 
> There are of course many various small fixes and enhancements, so
> a very big thank you to everyone that has contributed.
> 
> 
> As always feedback welcome!
> 
> 
> ## 1.9.198
> 
> 
> ### Enhancements
> * CLJS-1508: Extend ns form to support :rename option
> * CLJS-1507: Implicit macro loading: macro var inference in :refer
> * CLJS-1692: Autoalias clojure.* to exisiting cljs.* namespaces if
> possible
> * CLJS-1350: Compiler support for browser REPL
> * CLJS-1729: Support `use` special function in REPLs
> * CLJS-1730: Support `refer-clojure` special function in REPLs
> 
> 
> ### Changes
> * CLJS-1515: Self-host: Allow :file key in cljs.js/*load-fn*
> * add toString implementation to Vars
> * Use a js array to create collections in cljs.reader
> * CLJS-1640: Use the unshaded version of the closure compiler
> * add :browser-repl to list of known opts
> * add browser REPL preload
> * parity with Clojure 1.9.0-alpha10 clojure.spec
> * bump to tools.reader 1.0.0-beta3
> 
> 
> ### Fixes
> * CLJS-1733: Macro inference issue for macros & runtime vars with the same 
> name
> * CLJS-1735: Self-host: cljs.spec speced-vars instance
> * CLJS-1736: cljs.spec.test: checkable-syms* called with 0-arity
> * CLJS-1708: Self-host: [iu]nstrument-1 needs to qualify [iu]nstrument-1*
> * CLJS-1707: Self-host: with-instrument-disabled needs to qualify 
> *instrument-enabled*
> * CLJS-1732: Add docstrings for new use and use-macros REPL specials
> * CLJS-1720: Qualify symbols and namespaced keywords in spec macros
> * CLJS-1731: Self-host: do_template problem with script/test-self-parity
> * CLJS-1556: Invalid code emit for obj literal
> * CLJS-1607: bug with `specify!` in JS prototypes with `static-fns` true
> * CLJS-1591 avoid analyzing invoke arguments multiple times
> * CLJS-1638: :elide-asserts disables atom validators in :advanced
> * CLJS-1721: 3-arity get-in fails on types which do not implement ILookup
> * CLJS-1728: Update doc for ns for new :rename capability
> * CLJS-1727: Regression when evaluating non-sequential forms at the REPL
> * CLJS-1490: Watch macro files in cljs.build.api/watch
> * CLJS-1719: Port destructuring namespaced keys and symbols
> * CLJS-1653: cljs.spec: keys* causes exception
> * CLJS-1700: Support clojure.* aliasing when not in vector
> * CLJS-1717 remove map from equiv-map
> * CLJS-1716: No longer possible to use same alias for :require-macros and 
> :require
> * Use keyword options in js->clj 1-arg impl
> * Add support for regex in transit for compiler analysis cache
> * Escape non-Latin1 characters before base64 encoding the source-map string
> * CLJS-1698: cljs.spec: every res call needs &env
> * CLJS-1695: Self-host: Port cljs / clojure namespace aliasing
> * CLJS-1697: doc on inferred macros fails
> * CLJS-1699: Update docstring for ns
> * CLJS-1694: Self-host: Port macro var inference in :refer

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


Re: [ClojureScript] How can I get core.async to work in Cljs in Cljs

2016-07-06 Thread Zubair Quraishi
Hi Mike,
 I didn't necessarily mean that core.async is slow in my last comment, but more 
that macro evaluation can be slow. The clojurescript macro file in question is 
here:

https://github.com/zubairq/BlocklyBuilder/blob/master/src/webapp/framework/client/macros.cljs

It seems to take at least 5 seconds to compile in bootstrapped clojurescript. 
So are you saying that I can precompile and cache this file so that the browser 
never has to compile it?
thanks
Zubair


On Tuesday, July 5, 2016 at 9:11:49 PM UTC+2, Mike Fikes wrote:
> > i know I have been pushing for core.async to be pushed into master but I 
> > have since changed my mind as i have seen that running macros in 
> > bootstrapped clojurescript is very slow
> 
> Hey Zubair, 
> 
> For a library of the size of `core.async`, I’d recommend making use of 
> bootstrapped ClojureScript’s ability to cache the results of compilation. You 
> can at least eliminate 95% of the start up time (with Andare). Here is an 
> example (where the -K option to Planck enables caching):
> 
> $ time planck -Kc andare-0.2.0.jar -e"(require 'cljs.core.async)" 
> -e"(require-macros 'cljs.core.async.macros)" -e"(cljs.core.async.macros/go)"
> #object[cljs.core.async.impl.channels.ManyToManyChannel]
> 
> real  0m27.401s
> user  0m36.093s
> sys   0m0.940s
> 
> $ time planck -Kc andare-0.2.0.jar -e"(require 'cljs.core.async)" 
> -e"(require-macros 'cljs.core.async.macros)" -e"(cljs.core.async.macros/go)"
> #object[cljs.core.async.impl.channels.ManyToManyChannel]
> 
> real  0m1.505s
> user  0m2.658s
> sys   0m0.357s
> 
> - Mike

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


Re: [ClojureScript] How can I get core.async to work in Cljs in Cljs

2016-06-27 Thread Zubair Quraishi
On Friday, June 24, 2016 at 2:55:25 PM UTC+2, Mike Fikes wrote:
> Hi Zubair,
> 
> There are no plans on my part for pushing for that.
> 
> (My opinion: It is a relatively heavy set of code changes, useful only to a 
> small portion of the community. If bootstrap becomes important enough where 
> Cognitect would like to consider revising core.async for self-hosted use, at 
> least Andare exists as a working example of how it can be done.)
> 
> - Mike
> 
> > On Jun 24, 2016, at 8:19 AM, Zubair Quraishi  wrote:
> > 
> > Will this fork make it back in to the main branch at some point?
> > 
> >> On Saturday, May 14, 2016 at 5:16:10 PM UTC+2, Mike Fikes wrote:
> >>> On Tuesday, December 15, 2015 at 8:54:21 AM UTC-5, Zubair Quraishi wrote:
> >>> Hi Mike,
> >>> I took a quick look. Really happy that you are actively working on this 
> >>> too. When do you think a stable will be released? Just a ballpark figure 
> >>> I mean, so that I can plan around it?
> >>> thanks
> >>> Zubair
> >> 
> >> Hi Zubair,
> >> 
> >> Basic `core.async` constructs now work in self-hosted ClojureScript in the 
> >> fork I've been messing with. See 
> >> https://gist.github.com/mfikes/22f553d8c9186dcc613e1263ca9deeda
> >> 
> >> - Mike
> > 
> > -- 
> > Note that posts from new members are moderated - please be patient with 
> > your first post.
> > --- 
> > You received this message because you are subscribed to the Google Groups 
> > "ClojureScript" group.
> > To unsubscribe from this group and stop receiving emails from it, send an 
> > email to clojurescript+unsubscr...@googlegroups.com.
> > To post to this group, send email to clojurescript@googlegroups.com.
> > Visit this group at https://groups.google.com/group/clojurescript.

i know I have been pushing for core.async to be pushed into master but I have 
since changed my mind as i have seen that running macros in bootstrapped 
clojurescript is very slow

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


Re: [ClojureScript] How can I get core.async to work in Cljs in Cljs

2016-06-24 Thread Zubair Quraishi
Will this fork make it back in to the main branch at some point?

On Saturday, May 14, 2016 at 5:16:10 PM UTC+2, Mike Fikes wrote:
> On Tuesday, December 15, 2015 at 8:54:21 AM UTC-5, Zubair Quraishi wrote:
> > Hi Mike,
> >  I took a quick look. Really happy that you are actively working on this 
> > too. When do you think a stable will be released? Just a ballpark figure I 
> > mean, so that I can plan around it?
> > thanks
> > Zubair
> 
> Hi Zubair,
> 
> Basic `core.async` constructs now work in self-hosted ClojureScript in the 
> fork I've been messing with. See 
> https://gist.github.com/mfikes/22f553d8c9186dcc613e1263ca9deeda
> 
> - Mike

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


[ClojureScript] Re: [Ann] Andare: core.async for bootstrap ClojureScript

2016-06-24 Thread Zubair Quraishi
this is very cool, thanks!

On Sunday, May 22, 2016 at 4:09:06 AM UTC+2, Mike Fikes wrote:
> Andare is a fork of core.async ported for use with self-hosted ClojureScript.
> 
>   https://github.com/mfikes/andare
> 
> Available on Clojars: https://clojars.org/andare
> 
> A blog post: 
> http://blog.fikesfarm.com/posts/2016-05-15-bootstrap-core-async.html
> 
> The Andare repo also includes additional code to run the core.async unit 
> tests in a Node.js bootstrap ClojureScript environment. (The tests also pass 
> if loaded and executed in Planck.)
> 
> - Mike Fikes

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


[ClojureScript] Re: cljs.js/eval and functions/macros defined in user/custom namespace

2016-04-02 Thread Zubair Quraishi
Mike also helped me get this working for appshare.co. See the code here:

https://github.com/zubairq/AppShare/blob/master/idesandboxcode/myappshare/mainapp.cljs

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


[ClojureScript] Re: RDF and Sparql for clojurescript

2016-01-24 Thread Zubair Quraishi
I want to do the same from Clojurescript. Which one did you choose in the end?

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


[ClojureScript] Re: Compile ClojureScript in ClojureScript

2016-01-24 Thread Zubair Quraishi
Maybe this will help as I used macros from Clojurescript in clojurescript:

https://github.com/zubairq/AppShare/blob/master/idesandboxcode/myappshare/mainapp.cljs

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


[ClojureScript] Re: ANN replikativ 0.1.0 - strong eventual consistent P2P replication for clj and cljs

2016-01-20 Thread Zubair Quraishi
This is great work! Can it be compared to something like Datomic and Datascript?

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


[ClojureScript] Re: Does Om Next support query subscriptions?

2016-01-14 Thread Zubair Quraishi
I have an Om system that supports query subscriptions in a framework very much 
like Meteor, although it only handles SQL query subscriptions. You can see the 
code here:

https://github.com/zubairq/AppShare

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


[ClojureScript] Re: A basic clojurescript / om playground released at appshare.co

2016-01-01 Thread Zubair Quraishi
On Friday, January 1, 2016 at 5:24:30 PM UTC+1, Zubair Quraishi wrote:
> I'm building an online app builder and part of the foundation will be 
> Clojurescript and Om, so feel free to play around with it to try out snippets 
> of clojurescript

The link is http://appshare.co

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


[ClojureScript] A basic clojurescript / om playground released at appshare.co

2016-01-01 Thread Zubair Quraishi
I'm building an online app builder and part of the foundation will be 
Clojurescript and Om, so feel free to play around with it to try out snippets 
of clojurescript

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


Re: [ClojureScript] Bootstrap Clojurescript & args does not eval in macros in webkit browsers

2015-12-29 Thread Zubair Quraishi
hi Mike, 
Thanks again for your help. You can see the result here:

appshare.co

So you can edit and save basic clojurescript Om apps in the browser.
Zubair

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


Re: [ClojureScript] Bootstrap Clojurescript & args does not eval in macros in webkit browsers

2015-12-29 Thread Zubair Quraishi
Hi Mike,

Ok, tested on Mac Safari. Set :static-fns true and now:

(js/alert (test-macro))

works, and outputs 58. thanks so much for your help!!!
Zubair

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


Re: [ClojureScript] Bootstrap Clojurescript & args does not eval in macros in webkit browsers

2015-12-29 Thread Zubair Quraishi
Hi Mike,
 Ok, first test, Windows Firefox, Chrome and IE11 setting:

:static-fns false

in two places, here and here works:

:compiler {:output-to "target/cljsbuild/public/js/app.js"
  :output-dir "target/cljsbuild/public/js/out"
  :asset-path   "js/out"
  :optimizations :none
  :static-fns false
  :pretty-print  true

:and:

(cljs/eval-str
   (cljs/empty-state)

   src

   'foo.bar

   {:evalcljs/js-eval
:source-map   true
:loadload-fn
:static-fns  false
:def-emits-var   true
:ns  cljs-eval-example.fns}


I'll try on Mac Safari in a minute

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


Re: [ClojureScript] Bootstrap Clojurescript & args does not eval in macros in webkit browsers

2015-12-29 Thread Zubair Quraishi
Hi Mike,
 I have managed to reproduce the problem now and put it up on github. So:

1) git clone https://github.com/zubairq/cljs-eval-example.git

2) cd cljs-eval-example

3) lein.sh figwheel

4) Go to 127.0.0.1:3449.

This will bring up a repl in the browser. Enter anything in Chrome or Firefox 
works, try :

(js/alert (test-macro))

:Should popup an alert saying 58, but in Mac Safari the browser just hangs. The 
test-macro is defined as:

(defmacro test-macro [& more] 58)

:and it is imported with:

(:require-macros 
  [cljs-eval-example.macros :refer [ test-macro ]])

: as explained in your blog post. Am I doing something wrong or is this a bug 
in cljs?

Thanks
Zubair

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


Re: [ClojureScript] Bootstrap Clojurescript & args does not eval in macros in webkit browsers

2015-12-29 Thread Zubair Quraishi
On Monday, December 28, 2015 at 10:49:19 PM UTC+1, Mike Fikes wrote:
> Yes, this is because the underlying function that implements a macro take two 
> extra hidden arguments associated with the &env and &form special variables. 
> These are implicitly passed when a macro is consumed from a namespace that 
> does :require-macros to access the macro, but not when you consume a macro in 
> the same compilation stage where it was defined (a pattern that is supported 
> in Clojure, but not ClojureScript).
> 
> To experiment with macros in REPLs like clojurescript.io—where you can't use 
> :require-macros for custom macros you are defining—I usually play games with 
> the compiler, defining and invoking macros in a way that is **unsupported**, 
> but nevertheless successfully violates the compiler's abstractions. See: 
> http://blog.fikesfarm.com/posts/2015-09-07-messing-with-macros-at-the-repl.html
> 
> 
> > On Dec 28, 2015, at 1:16 PM, Zubair Quraishi  wrote:
> > 
> > I tried the clojurescript.io on Chrome as well, and see the following with 
> > defmacro:
> > 
> > cljs.user=> (defmacro somemacro [] 5)
> > true
> > cljs.user=> (somemacro )
> > Wrong number of args (0) passed to cljs.user/somemacro at line 1 
> > cljs.user=> (somemacro)
> > Wrong number of args (0) passed to cljs.user/somemacro at line 1 
> > cljs.user=> (somemacro 1)
> > Wrong number of args (1) passed to cljs.user/somemacro at line 1 
> > cljs.user=> (somemacro 2)
> > Wrong number of args (1) passed to cljs.user/somemacro at line 1 
> > cljs.user=> 
> > 
> >> On Monday, December 28, 2015 at 3:29:30 PM UTC+1, Mike Fikes wrote:
> >> Hi Zubair,
> >> 
> >> It works in clojurescript.io on iPhone Safari.
> >> 
> >> But, it would be interesting to separate the macro use from the alert.
> >> 
> >> (The macro is incorrectly being used directly in the same compilation 
> >> stage where it is being defined—instead it needs to be separately brought 
> >> in via :require-macros).
> >> 
> >> See: 
> >> https://github.com/clojure/clojurescript/wiki/Differences-from-Clojure#macros
> >> 
> >> - Mike
> >> 
> >> 
> >>> On Dec 28, 2015, at 8:54 AM, Zubair Quraishi  wrote:
> >>> 
> >>> I've noticed that the following bootstrapped Clojurescript works in 
> >>> Chrome and Firefox using eval, but not on Webkit browsers such as iPhone, 
> >>> Safari, iPad:
> >>> 
> >>> (ns some-namespace) 
> >>> 
> >>> (defmacro some-macro [& more]  5  ) 
> >>> (js/alert (pr-str (some-macro 1)))
> >>> 
> >>> It should alert 5 on the screen but in Webkit the browser crashes.  I've 
> >>> tested in Clojurescript 1.7.189 and 1.7.170
> >>> 
> >>> Anyone experienced anything similar?
> >>> 
> >>> -- 
> >>> Note that posts from new members are moderated - please be patient with 
> >>> your first post.
> >>> --- 
> >>> You received this message because you are subscribed to the Google Groups 
> >>> "ClojureScript" group.
> >>> To unsubscribe from this group and stop receiving emails from it, send an 
> >>> email to clojurescript+unsubscr...@googlegroups.com.
> >>> To post to this group, send email to clojurescript@googlegroups.com.
> >>> Visit this group at https://groups.google.com/group/clojurescript.
> > 
> > -- 
> > Note that posts from new members are moderated - please be patient with 
> > your first post.
> > --- 
> > You received this message because you are subscribed to the Google Groups 
> > "ClojureScript" group.
> > To unsubscribe from this group and stop receiving emails from it, send an 
> > email to clojurescript+unsubscr...@googlegroups.com.
> > To post to this group, send email to clojurescript@googlegroups.com.
> > Visit this group at https://groups.google.com/group/clojurescript.

Ok thanks, that article made me understand the cljs macros much better and 
explains why I got that message, thanks!

I think what I will do is make a minimal use case for the issue I was facing 
and put it up on github, as then it makes it easy to reproduce. 

Thanks for you time so far Mike, really appreciated, especially over the 
holidays! :)

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


Re: [ClojureScript] Bootstrap Clojurescript & args does not eval in macros in webkit browsers

2015-12-28 Thread Zubair Quraishi
I tried the clojurescript.io on Chrome as well, and see the following with 
defmacro:

cljs.user=> (defmacro somemacro [] 5)
true
cljs.user=> (somemacro )
Wrong number of args (0) passed to cljs.user/somemacro at line 1 
cljs.user=> (somemacro)
Wrong number of args (0) passed to cljs.user/somemacro at line 1 
cljs.user=> (somemacro 1)
Wrong number of args (1) passed to cljs.user/somemacro at line 1 
cljs.user=> (somemacro 2)
Wrong number of args (1) passed to cljs.user/somemacro at line 1 
cljs.user=> 

On Monday, December 28, 2015 at 3:29:30 PM UTC+1, Mike Fikes wrote:
> Hi Zubair,
> 
> It works in clojurescript.io on iPhone Safari.
> 
> But, it would be interesting to separate the macro use from the alert.
> 
> (The macro is incorrectly being used directly in the same compilation stage 
> where it is being defined—instead it needs to be separately brought in via 
> :require-macros).
> 
> See: 
> https://github.com/clojure/clojurescript/wiki/Differences-from-Clojure#macros
> 
> - Mike
> 
> 
> > On Dec 28, 2015, at 8:54 AM, Zubair Quraishi  wrote:
> > 
> > I've noticed that the following bootstrapped Clojurescript works in Chrome 
> > and Firefox using eval, but not on Webkit browsers such as iPhone, Safari, 
> > iPad:
> > 
> > (ns some-namespace) 
> > 
> > (defmacro some-macro [& more]  5  ) 
> > (js/alert (pr-str (some-macro 1)))
> > 
> > It should alert 5 on the screen but in Webkit the browser crashes.  I've 
> > tested in Clojurescript 1.7.189 and 1.7.170
> > 
> > Anyone experienced anything similar?
> > 
> > -- 
> > Note that posts from new members are moderated - please be patient with 
> > your first post.
> > --- 
> > You received this message because you are subscribed to the Google Groups 
> > "ClojureScript" group.
> > To unsubscribe from this group and stop receiving emails from it, send an 
> > email to clojurescript+unsubscr...@googlegroups.com.
> > To post to this group, send email to clojurescript@googlegroups.com.
> > Visit this group at https://groups.google.com/group/clojurescript.

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


Re: [ClojureScript] Bootstrap Clojurescript & args does not eval in macros in webkit browsers

2015-12-28 Thread Zubair Quraishi
On Monday, December 28, 2015 at 3:29:30 PM UTC+1, Mike Fikes wrote:
> Hi Zubair,
> 
> It works in clojurescript.io on iPhone Safari.
> 
> But, it would be interesting to separate the macro use from the alert.
> 
> (The macro is incorrectly being used directly in the same compilation stage 
> where it is being defined—instead it needs to be separately brought in via 
> :require-macros).
> 
> See: 
> https://github.com/clojure/clojurescript/wiki/Differences-from-Clojure#macros
> 
> - Mike
> 
> 
> > On Dec 28, 2015, at 8:54 AM, Zubair Quraishi  wrote:
> > 
> > I've noticed that the following bootstrapped Clojurescript works in Chrome 
> > and Firefox using eval, but not on Webkit browsers such as iPhone, Safari, 
> > iPad:
> > 
> > (ns some-namespace) 
> > 
> > (defmacro some-macro [& more]  5  ) 
> > (js/alert (pr-str (some-macro 1)))
> > 
> > It should alert 5 on the screen but in Webkit the browser crashes.  I've 
> > tested in Clojurescript 1.7.189 and 1.7.170
> > 
> > Anyone experienced anything similar?
> > 
> > -- 
> > Note that posts from new members are moderated - please be patient with 
> > your first post.
> > --- 
> > You received this message because you are subscribed to the Google Groups 
> > "ClojureScript" group.
> > To unsubscribe from this group and stop receiving emails from it, send an 
> > email to clojurescript+unsubscr...@googlegroups.com.
> > To post to this group, send email to clojurescript@googlegroups.com.
> > Visit this group at https://groups.google.com/group/clojurescript.

Which version of clojurescript is clojurescript.io using. Is it Clojurescript 
1.7.189 or 1.7.170?

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


Re: [ClojureScript] Bootstrap Clojurescript & args does not eval in macros in webkit browsers

2015-12-28 Thread Zubair Quraishi
I tried it with require-macros but get the same behaviour on Mac Safari. 

I tried clojurescript.io on my Mac Safari and it works but I also get the 
message:

Wrong number of args (1) passed to some-namespace/some-macro at line 4 

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


[ClojureScript] Bootstrap Clojurescript & args does not eval in macros in webkit browsers

2015-12-28 Thread Zubair Quraishi
I've noticed that the following bootstrapped Clojurescript works in Chrome and 
Firefox using eval, but not on Webkit browsers such as iPhone, Safari, iPad:

(ns some-namespace) 

(defmacro some-macro [& more]  5  ) 
(js/alert (pr-str (some-macro 1)))

It should alert 5 on the screen but in Webkit the browser crashes.  I've tested 
in Clojurescript 1.7.189 and 1.7.170

Anyone experienced anything similar?

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


[ClojureScript] Re: [ANN] kabel 0.1.0 release

2015-12-24 Thread Zubair Quraishi
I like the idea of this. Isn't there anything similar already in Cljs and 
Clojure though?

On Thursday, December 24, 2015 at 6:03:50 PM UTC+1, white...@polyc0l0r.net 
wrote:
> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA1
> 
> Hello,
> 
> I am happy to announce the first independent release of kabel (German
> for wire or cable), a websocket library that is used by several of my
> projects. From the REAMDE:
> 
> kabel is a minimal, modern connection library modelling a
> bidirectional wire to pass clojure values between endpoints. Peers in
> Clojure and ClojureScript are symmetric and hence allow symmetric
> cross-platform implementations. At the moment web-sockets are used and
> transit is the serialization format.
> 
> https://github.com/replikativ/kabel
> 
> I hope it is useful for others as well. Feedback is appreciated :)
> 
> Christian
> -BEGIN PGP SIGNATURE-
> Version: GnuPG v2.0.22 (GNU/Linux)
> 
> iQEcBAEBAgAGBQJWfCVxAAoJEKel+aujRZMk5g4H/0Wp84eGotnBwQItb17NsGc+
> /Vt5HiG9nEO1FriylPMkoGgnwhdYDKs7BXhJJGPB9JIe2adJKZFQgL9Wpx0WiLC/
> borxP7LcwmY1sbFquy+AZ5+kl6PSqDyM0eolfKuL+kRlXgaFeMhfopZ3562yLf71
> FjQmn2NS+h+i0OP+obSjl+dDJFE8ndv7lJYgWXWklnDZST9ctVNVD+kyY0nXXfo3
> db5wcGvtU0MBhngzDMyhzrJtgXp4RqvcIMICesN63osFkfADzKWo2VKV/MSxPNk1
> ZsYB89OxBzWuj6fmIEBZQ+v9HDTbExiVr467W0N2DL67YcjqyAzKrDOERu1MaCc=
> =y9hg
> -END PGP SIGNATURE-

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


[ClojureScript] Re: Pdf Generation with Clojurescript

2015-12-23 Thread Zubair Quraishi
On Wednesday, December 23, 2015 at 9:08:17 AM UTC+1, Matthew Molloy wrote:
> Anybody tackled this?  There is a js lib called http://pdfkit.org/, I could 
> write a wrapper.

I have done PDF generation via Clojurescript but just called the server 
generated PDF made with Clojure. I would warn that there are Javascript 
libraries you can call but the results are not as good as something like server 
side iText PDF generation (via Java)

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


[ClojureScript] Cljs in Cljs Om playground

2015-12-21 Thread Zubair Quraishi
I have made a cljs in cljs playground with Om. You can try it here:

http://appshare.co

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


Re: [ClojureScript] How can I get core.async to work in Cljs in Cljs

2015-12-15 Thread Zubair Quraishi
Ok, thanks for the update

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


Re: [ClojureScript] How can I get core.async to work in Cljs in Cljs

2015-12-15 Thread Zubair Quraishi
Ok, makes sense. Is there a roadmap or something for Clojurescript in 
Clojurescript so I can get a better sense of what it will and won't support in 
the future?

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


Re: [ClojureScript] How can I get core.async to work in Cljs in Cljs

2015-12-15 Thread Zubair Quraishi
Ok, but how does it work right now. Are you the main contributor for core.async 
for ClojureScript, or is someone at Cognitect working on it as well?

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


Re: [ClojureScript] How can I get core.async to work in Cljs in Cljs

2015-12-15 Thread Zubair Quraishi
Hi Mike,
 I took a quick look. Really happy that you are actively working on this too. 
When do you think a stable will be released? Just a ballpark figure I mean, so 
that I can plan around it?
thanks
Zubair

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


[ClojureScript] Re: How can I get core.async to work in Cljs in Cljs

2015-12-15 Thread Zubair Quraishi
I also tried to do:

  (:require-macros
[cljs.core.async.macros :refer [go]]
))

:but when I compile I get:

{:error #error {:message "Could not eval cljs.core.async.macros", :data {:tag 
:cljs/analysis-error}, :cause #error {:message "Invalid token: //", :data 
{:type :reader-exception, :line 11, :column 27, :file cljs.core.async.macros

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


[ClojureScript] How can I get core.async to work in Cljs in Cljs

2015-12-15 Thread Zubair Quraishi
I am trying to get core.async (go macros to work in cljs in cljs but they seem 
to do nothing. I try fully qualifying them as well with 
(cljs.core.async.macros/go but it makes no difference. Anyone else have 
core.async working with cljs in cljs?

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


[ClojureScript] Re: Can not "require" om.next in clojureScript (in clojurescript)

2015-12-15 Thread Zubair Quraishi
Hi Mike,
 I am able to get around the problem by just putting the full namespace before 
my om elements, like so:

(om.dom/div ... blah blah blah

: and this seems to work fine.
Thanks
Zubair

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at https://groups.google.com/group/clojurescript.


[ClojureScript] Can not "require" om.next in clojureScript (in clojurescript)

2015-12-10 Thread Zubair Quraishi
When I try to require om.next in self hosted ClojureScrtipt I get this message:

:error #error {:message "Could not eval om.next", :data {:tag 
:cljs/analysis-error}, :cause #error {:message "Invalid token: //", :data 
{:type :reader-exception, :line 11, :column 27, :file om.next

Any ideas as to how to get around this?

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: In Clojurescript Compiler how to change the namespace?

2015-12-10 Thread Zubair Quraishi
I figured it out in the end, doing this:


  (cljs/eval-str (cljs/empty-state) string-to-evaulate 'foo.bar
{
  :eval cljs/js-eval
  :load load-fn
  :source-map true}
(fn [result]
  (do
(js/eval (:value result))
result

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: In Clojurescript Compiler how to change the namespace?

2015-12-09 Thread Zubair Quraishi
I tried using :in-ns but it was just ignored. I looked at replumb but I was not 
sure what to look for. I guess I was confused as when I saw David Nolen's 
original post here:

http://swannodette.github.io/2015/07/29/clojurescript-17/

: He shows this example:

(ns foo.core
  (:require-macros
[bar.core :refer [mult]]))

(mult 4 4)

:but I can't seem to figure out how he evaled that text so that it parsed both 
the ns and the mult forms

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: macros in pure clojurescript

2015-12-09 Thread Zubair Quraishi
On Tuesday, December 8, 2015 at 6:01:31 PM UTC+1, Rafik NACCACHE wrote:
> Hi Guys,
> 
> I think ClojureScript deserves its own macros and eval.
> 
> Any plans to work on this?
> 
> Cheers,
> 
> Rafik

Clojurescript already has both of these in the cljs.js namespace, have you seen 
this?

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] In Clojurescript Compiler how to change the namespace?

2015-12-08 Thread Zubair Quraishi
I try something like:

(cljs/eval (cljs/empty-state)
(read-string s)
{:eval   cljs/js-eval
 :source-map true
 :context:expr
 :def-emits-var true
 :ns my.namespace
 }
(fn [result] result)))



but my.namespace seems to cause it to not work with no errors

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: Idea for a reactive and faster alternative to Datascript

2015-12-08 Thread Zubair Quraishi
On Tuesday, December 8, 2015 at 11:13:25 AM UTC+1, Vianney Stroebel (vibl) 
wrote:
> Ok, I guess this idea is so stupid nobody even bothers saying it is. :-)
> 
> Vianney
> 
> On Thursday, December 3, 2015 at 3:40:56 PM UTC+1, Vianney Stroebel (vibl) 
> wrote:
> > I posted an idea for a reactive and faster alternative to Datascript:
> > 
> > https://github.com/tonsky/datascript/issues/132
> > 
> > It seems too good to be true on paper so I probably have overlooked things.
> > 
> > Comments are welcome!
> > 
> > Vianney

A shame that noone replied. I have not used Datomic so can not comment on it

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: Examples of Om with Clojurescript in Clojurescript

2015-12-08 Thread Zubair Quraishi
On Friday, December 4, 2015 at 1:58:51 PM UTC+1, bpb...@gmail.com wrote:
> I haven't got an online example as it's for work, but it's quite easy to set 
> up a component that evaluates code

Ok, thanks, so are you saying there are no examples yet, as I see that Reagent 
has some examples already

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Examples of Om with Clojurescript in Clojurescript

2015-12-03 Thread Zubair Quraishi
I am using Om and would like to move from Figwheel to cljs in cljs for an 
online clojurescript editor I am making. Are there any examples of Om in a 
hosted browser environment?

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] I'm building something like Meteor.js in Clojurescript. Feedback welcome

2015-06-26 Thread Zubair Quraishi
https://github.com/zubairq/coils

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: honeysql now available from Clojurescript

2015-06-18 Thread Zubair Quraishi
If I use HoneySQL in clojure script then does it use core.async to return the 
results?


On Monday, June 15, 2015 at 2:02:44 AM UTC+2, Michael Blume wrote:
> Using reader conditionals, I've put up an experimental branch of honeysql 
> which seems to work just fine from both Clojure and Clojurescript. If you 
> need to generate SQL from your Node service, please try it out.
> 
> 
> https://github.com/michaelblume/honeysql/tree/rcond
> 
> 
> 
> Will update soon with my experiences, ran into a few rough edges during the 
> port, but everything seems to work pretty nicely.

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: Isomorphic ClojureScript

2015-05-20 Thread Zubair Quraishi
On Tuesday, May 19, 2015 at 7:17:10 PM UTC+2, marc fawzi wrote:
> Is anyone out there working on a pattern of framework for isomorphic 
> ClojureScript?
> 
> My sense so far is that most are happy running Clojure on back end and 
> ClojureScript on front end. But Matt's recent post made me think of 
> Isomorphic apps. For example, you can have the 1st page render server side so 
> it's pre-rendered for faster load, and then have the rest of the app (all 
> other pages) run in the client. 
> 
> Meteor just got $20M to build the isomorphic js framework to rule them all.
> 
> Any interest in this within the ClojureScript community?
> 
> Sent from my iPhone

And yes, I am working on a similar one for Clojure still in progress but 
will be Clojure on server and Clojurescript on frontend and have real time 
support for databases (the old version is up on github, but new one going up 
soon):

https://github.com/zubairq/coils

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: Isomorphic ClojureScript

2015-05-20 Thread Zubair Quraishi
On Tuesday, May 19, 2015 at 7:17:10 PM UTC+2, marc fawzi wrote:
> Is anyone out there working on a pattern of framework for isomorphic 
> ClojureScript?
> 
> My sense so far is that most are happy running Clojure on back end and 
> ClojureScript on front end. But Matt's recent post made me think of 
> Isomorphic apps. For example, you can have the 1st page render server side so 
> it's pre-rendered for faster load, and then have the rest of the app (all 
> other pages) run in the client. 
> 
> Meteor just got $20M to build the isomorphic js framework to rule them all.
> 
> Any interest in this within the ClojureScript community?
> 

This is incorrect, Meteor got 20 million to build a "full stack" and "real 
time" framework. That is what the investors are eyeing. The fact that it is 
Javascript on the front end is important, but not the backend

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: Would anyone like to make a video interview about Light Table / Clojurescript with me?

2015-03-18 Thread Zubair Quraishi
Thanks, Michael Klishin of Clojurewerkz just made the first interview:

https://www.youtube.com/watch?v=nPO3AIxkMoE

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: Resources for Getting Started with Clojurescript

2015-03-13 Thread Zubair Quraishi
I have some videos you may find useful:

http://www.zubairquraishi.com/zubairquraishi/clojurescript--light-table.html

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


Re: [ClojureScript] Re: Example of a working macro?

2015-03-04 Thread Zubair Quraishi
Sure, zubairquraishi.com

On Tuesday, March 3, 2015 at 6:42:00 PM UTC+1, marc fawzi wrote:
> Thank you very much Zubair!  Do you have a blog or active twitter?  Would 
> love to follow.
> 
> Sent from my iPhone
> 
> > On Mar 3, 2015, at 8:43 AM, Zubair Quraishi  wrote:
> > 
> > There are several macros in my github project:
> > 
> > https://github.com/zubairq/coils
> > 
> > 
> > 
> >> On Tuesday, March 3, 2015 at 5:13:06 PM UTC+1, marc fawzi wrote:
> >> Hi,
> >> 
> >> 
> >> I tried defmacro from a .clj file with proper namespace and I did a 
> >> :require-macros (with standard :refer) to point to it from my .cljs file
> >> 
> >> 
> >> I thought I should maybe tell Leinigen something about the .clj file 
> >> containing the macro but I'm not sure what is needed there.
> >> 
> >> 
> >> Does anyone have a clue? or know of a CLJS project on github where macros 
> >> are used?
> >> 
> >> 
> >> Thanks,
> >> Marc
> > 
> > -- 
> > Note that posts from new members are moderated - please be patient with 
> > your first post.
> > --- 
> > You received this message because you are subscribed to the Google Groups 
> > "ClojureScript" group.
> > To unsubscribe from this group and stop receiving emails from it, send an 
> > email to clojurescript+unsubscr...@googlegroups.com.
> > To post to this group, send email to clojurescript@googlegroups.com.
> > Visit this group at http://groups.google.com/group/clojurescript.

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


Re: [ClojureScript] Re: Example of a working macro?

2015-03-04 Thread Zubair Quraishi
Thanks for the info, I will fix the documentation as soon as possible!


On Tuesday, March 3, 2015 at 7:06:13 PM UTC+1, Colin Yates wrote:
> (by the way, the demo link in the coils repo is dead)
> 
> On 3 March 2015 at 16:43, Zubair Quraishi  wrote:
> > There are several macros in my github project:
> >
> > https://github.com/zubairq/coils
> >
> >
> >
> > On Tuesday, March 3, 2015 at 5:13:06 PM UTC+1, marc fawzi wrote:
> >> Hi,
> >>
> >>
> >> I tried defmacro from a .clj file with proper namespace and I did a 
> >> :require-macros (with standard :refer) to point to it from my .cljs file
> >>
> >>
> >> I thought I should maybe tell Leinigen something about the .clj file 
> >> containing the macro but I'm not sure what is needed there.
> >>
> >>
> >> Does anyone have a clue? or know of a CLJS project on github where macros 
> >> are used?
> >>
> >>
> >> Thanks,
> >> Marc
> >
> > --
> > Note that posts from new members are moderated - please be patient with 
> > your first post.
> > ---
> > You received this message because you are subscribed to the Google Groups 
> > "ClojureScript" group.
> > To unsubscribe from this group and stop receiving emails from it, send an 
> > email to clojurescript+unsubscr...@googlegroups.com.
> > To post to this group, send email to clojurescript@googlegroups.com.
> > Visit this group at http://groups.google.com/group/clojurescript.

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: Example of a working macro?

2015-03-03 Thread Zubair Quraishi
There are several macros in my github project:

https://github.com/zubairq/coils



On Tuesday, March 3, 2015 at 5:13:06 PM UTC+1, marc fawzi wrote:
> Hi,
> 
> 
> I tried defmacro from a .clj file with proper namespace and I did a 
> :require-macros (with standard :refer) to point to it from my .cljs file
> 
> 
> I thought I should maybe tell Leinigen something about the .clj file 
> containing the macro but I'm not sure what is needed there.
> 
> 
> Does anyone have a clue? or know of a CLJS project on github where macros are 
> used?
> 
> 
> Thanks,
> Marc

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: Abstract some boilerplate code

2015-03-03 Thread Zubair Quraishi
You would have to use a Clojure macro to abstract this, which in turn will call 
a paramaterised function

On Sunday, March 1, 2015 at 4:24:18 PM UTC+1, Sven Richter wrote:
> Hi,
> 
> I have several functions that do an async request to the server. There are 
> constraints for this functions.
> 
> 1. Only send an request if some value is not empty
> 2. Disable and enable some button before and after the request. 
> 
> A function might look like this:
> 
> (defn add-group []
>   (let [g-name (h/get-value "add-group-input")
> ;repetitive get element
> clicked-button (h/get-elem "add-group-btn")] 
> ;repetitive only send when not empty
> (when (not-empty g-name)
>   (go (let [[ok uuid] ( clicked-button))]
>(if ok (do (swap! app-state update-in [:groups] conj {:name g-name 
> :uuid uuid})
>   (set-user-selection-hidden-state (:groups @app-state))
>   (h/show-success-message "notification-div" "Group 
> Added"))
>   (h/show-error-message "notification-div"))
> ;repetitive remove disbled attribute
>(.removeAttribute clicked-button "disabled"))
> 
> How would I put this repeating code into a function? Or would I need to write 
> a macro for this kind of repetition?
> 
> Best Regards,
> Sven

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: Om subtrees

2015-01-29 Thread Zubair Quraishi
On Wednesday, January 28, 2015 at 3:51:21 PM UTC+1, Colin Yates wrote:
> I am not sure of the exact interaction between om and react (other than om 
> implements react's lifecycle for performance enhancements), but two things 
> occur:
>  - this sounds like a loaded question - are you seeing some surprising 
> behaviour? 
>  - "deleted and then reinserted" isn't part of om's lifecycle; there is only 
> state. How it got to that state isn't interesting.
> 
> AIUI, at runtime, when state changes om will look at each component and check 
> the (app and local) state used to last render that component. If the state 
> has changed then the component is "updated", if not it isn't. The "updated" 
> component is then passed to react to do the actual rendering (of which there 
> might be none).
> 
> I am beating around the bush of saying, this isn't something I have had to 
> worry about - is there a specific problem you are seeing?
> 
> On Wednesday, 28 January 2015 11:59:50 UTC, Zubair Quraishi  wrote:
> > I am building an application in Om and wanted to know what happens to an Om 
> > component when the global state containing the Om Component's part of the 
> > UI tree is deleted and then reinserted. Is the Om component garbage 
> > collected and then recreated automatically, or should the component be 
> > destroyed and recreated using some commands in Om?

I figured out the problem, and it was something I totally overlooked. I was 
mutating state in the render call, and then I was wondering why the sub 
components did not see the new state, but of course they will only see the new 
state on the "next" render

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: Om subtrees

2015-01-29 Thread Zubair Quraishi
mmm, yes the component should handle everything itself. I am seeing strange 
behaviour so I am currently trying to break out a small example, in the hope 
that either I find the bug, or have a standalone reproducable problem which I 
can show

On Wednesday, January 28, 2015 at 3:51:21 PM UTC+1, Colin Yates wrote:
> I am not sure of the exact interaction between om and react (other than om 
> implements react's lifecycle for performance enhancements), but two things 
> occur:
>  - this sounds like a loaded question - are you seeing some surprising 
> behaviour? 
>  - "deleted and then reinserted" isn't part of om's lifecycle; there is only 
> state. How it got to that state isn't interesting.
> 
> AIUI, at runtime, when state changes om will look at each component and check 
> the (app and local) state used to last render that component. If the state 
> has changed then the component is "updated", if not it isn't. The "updated" 
> component is then passed to react to do the actual rendering (of which there 
> might be none).
> 
> I am beating around the bush of saying, this isn't something I have had to 
> worry about - is there a specific problem you are seeing?
> 
> On Wednesday, 28 January 2015 11:59:50 UTC, Zubair Quraishi  wrote:
> > I am building an application in Om and wanted to know what happens to an Om 
> > component when the global state containing the Om Component's part of the 
> > UI tree is deleted and then reinserted. Is the Om component garbage 
> > collected and then recreated automatically, or should the component be 
> > destroyed and recreated using some commands in Om?

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Om subtrees

2015-01-28 Thread Zubair Quraishi
I am building an application in Om and wanted to know what happens to an Om 
component when the global state containing the Om Component's part of the UI 
tree is deleted and then reinserted. Is the Om component garbage collected and 
then recreated automatically, or should the component be destroyed and 
recreated using some commands in Om?

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: Would anyone like to make a video interview about Light Table / Clojurescript with me?

2015-01-24 Thread Zubair Quraishi
Done:

https://github.com/zubairq/clojurescript_videos



On Sunday, January 25, 2015 at 12:40:05 AM UTC+1, Kaiyin Zhong wrote:
> On Thursday, January 22, 2015 at 10:14:19 AM UTC+1, Zubair Quraishi wrote:
> > Hi,
> > 
> > Would anyone like to make a video interview about Light Table / 
> > Clojurescript with me? I have already made some videos (just screencasts 
> > really) about Clojurescript and LightTable, but it has been a while since I 
> > made the last one. Would anyone like to make a video with me about their 
> > project or some feature of LightTable / Clojurescript? It can be published 
> > as the next episode? Here are the current videos:
> > 
> > http://www.zubairquraishi.com/zubairquraishi/clojurescript--light-table.html
> > 
> > We could do the interview/video over skype, and we could optionally use 
> > some screen recording software to show your screen too? My aim is not 
> > commercial, but just to learn Light Table and Clojurescript better. My 
> > current sticking point is tranducers by the way, which I just cannot get my 
> > head around, but any topics are welcome as I am not that good at 
> > Clojure/Clojurescript, I just muddle along somehow :)
> > 
> > Thanks
> > Zubair
> 
> Hi, Zubair.
> 
> Could you put this project on github or some other code hosting site?
> 
> Thanks!

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


Re: [ClojureScript] Can't find Om 0.8.1

2015-01-24 Thread Zubair Quraishi
Great, a useful resource. Thanks! :)

On Saturday, January 24, 2015 at 11:42:03 AM UTC+1, Daniel Kersten wrote:
> For future reference, I find searching clojars useful to fix issues like 
> this. Eg if you look for "0.8.1" on this page: https://clojars.org/search?q=om
> 
> 
> On Sat, 24 Jan 2015 08:56 Oliver George  wrote:
> 
> Happens to the best of us.
> 
> 
> On Sat, Jan 24, 2015 at 7:54 PM, Zubair Quraishi  wrote:
> Yes, it was staring me in the face. Thanks, that worked, I can be such a dumb 
> ass sometimes! :)
> 
> 
> 
> On Saturday, January 24, 2015 at 9:43:54 AM UTC+1, Oliver George wrote:
> 
> > I can reproduce that by removing the "org." bit I mentioned.  ANy chance 
> > it's been staring you in the face all along?  
> 
> >
> 
> >
> 
> > Make sure you have this exactly:  [org.om/om "0.8.1"]
> 
> >
> 
> >
> 
> >
> 
> >
> 
> >
> 
> >
> 
> >
> 
> >
> 
> > $ lein deps
> 
> > Could not find artifact om:om:jar:0.8.1 in central 
> > (https://repo1.maven.org/maven2/)
> 
> > Could not find artifact om:om:jar:0.8.1 in clojars 
> > (https://clojars.org/repo/)
> 
> > This could be due to a typo in :dependencies or network issues.
> 
> > If you are behind a proxy, try setting the 'http_proxy' environment 
> > variable.
> 
> >
> 
> >
> 
> >
> 
> >
> 
> > $ git diff project.clj
> 
> > diff --git a/wractioning-ui/project.clj b/wractioning-ui/project.clj
> 
> > index ad97a99..05479e1 100644
> 
> > --- a/wractioning-ui/project.clj
> 
> > +++ b/wractioning-ui/project.clj
> 
> > @@ -11,7 +11,7 @@
> 
> >                   [ring "1.3.1"]
> 
> >                   [compojure "1.2.0"]
> 
> >                   [enlive "1.1.5"]
> 
> > -                 [org.om/om "0.8.1"]
> 
> > +                 [om/om "0.8.1"]
> 
> >                   [figwheel "0.1.4-SNAPSHOT"]
> 
> >                   [environ "1.0.0"]
> 
> >                   [com.cemerick/piggieback "0.1.3"]
> 
> >
> 
> >
> 
> 
> 
> > On Sat, Jan 24, 2015 at 7:40 PM, Zubair Quraishi  wrote:
> 
> > MMM, I took a look at your project.clj, I see there are no repos defined. I 
> > tried removing them from my project.clj but I still get:
> 
> >
> 
> >
> 
> >
> 
> > Could not find artifact om:om:jar:0.8.1 in central 
> > (http://repo1.maven.org/maven2/)
> 
> >
> 
> > Could not find artifact om:om:jar:0.8.1 in clojars 
> > (https://clojars.org/repo/)
> 
> >
> 
> >
> 
> >
> 
> >
> 
> >
> 
> > On Saturday, January 24, 2015 at 9:21:24 AM UTC+1, Oliver George wrote:
> 
> >
> 
> > > Here's how I depend on om 0.8.1...
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > > https://gist.github.com/olivergeorge/ebc5b5f37132fd90d1ea#file-project-clj-L14
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > > (Someone else might need to comment on :repositories side of things)
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> >
> 
> >
> 
> > > On Sat, Jan 24, 2015 at 7:13 PM, Zubair Quraishi  wrote:
> 
> >
> 
> > > My repositories in project.clj looks like this:
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > >   :repositories {"sonatype-oss-public"
> 
> >
> 
> > >
> 
> >
> 
> > >                  "https://oss.sonatype.org/content/groups/public/";
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > >                  "aa"
> 
> >
> 
> > >
> 
> >
> 
> > >                  "https://clojars.org/org.om/om"}
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > > On Saturday, January 24, 2015 at 7:23:34 AM UTC+1, Oliver George wrote:
> 
> >
> 
> > >
> 
> >
> 
> > > >

Re: [ClojureScript] Can't find Om 0.8.1

2015-01-24 Thread Zubair Quraishi
Yes, it was staring me in the face. Thanks, that worked, I can be such a dumb 
ass sometimes! :)

On Saturday, January 24, 2015 at 9:43:54 AM UTC+1, Oliver George wrote:
> I can reproduce that by removing the "org." bit I mentioned.  ANy chance it's 
> been staring you in the face all along?  
> 
> 
> Make sure you have this exactly:  [org.om/om "0.8.1"]
> 
> 
> 
> 
> 
> 
> 
> 
> $ lein deps
> Could not find artifact om:om:jar:0.8.1 in central 
> (https://repo1.maven.org/maven2/)
> Could not find artifact om:om:jar:0.8.1 in clojars (https://clojars.org/repo/)
> This could be due to a typo in :dependencies or network issues.
> If you are behind a proxy, try setting the 'http_proxy' environment variable.
> 
> 
> 
> 
> $ git diff project.clj
> diff --git a/wractioning-ui/project.clj b/wractioning-ui/project.clj
> index ad97a99..05479e1 100644
> --- a/wractioning-ui/project.clj
> +++ b/wractioning-ui/project.clj
> @@ -11,7 +11,7 @@
>                   [ring "1.3.1"]
>                   [compojure "1.2.0"]
>                   [enlive "1.1.5"]
> -                 [org.om/om "0.8.1"]
> +                 [om/om "0.8.1"]
>                   [figwheel "0.1.4-SNAPSHOT"]
>                   [environ "1.0.0"]
>                   [com.cemerick/piggieback "0.1.3"]
> 
> 
> On Sat, Jan 24, 2015 at 7:40 PM, Zubair Quraishi  wrote:
> MMM, I took a look at your project.clj, I see there are no repos defined. I 
> tried removing them from my project.clj but I still get:
> 
> 
> 
> Could not find artifact om:om:jar:0.8.1 in central 
> (http://repo1.maven.org/maven2/)
> 
> Could not find artifact om:om:jar:0.8.1 in clojars (https://clojars.org/repo/)
> 
> 
> 
> 
> 
> On Saturday, January 24, 2015 at 9:21:24 AM UTC+1, Oliver George wrote:
> 
> > Here's how I depend on om 0.8.1...
> 
> >
> 
> >
> 
> >
> 
> >
> 
> > https://gist.github.com/olivergeorge/ebc5b5f37132fd90d1ea#file-project-clj-L14
> 
> >
> 
> >
> 
> >
> 
> > (Someone else might need to comment on :repositories side of things)
> 
> >
> 
> >
> 
> >
> 
> >
> 
> 
> 
> > On Sat, Jan 24, 2015 at 7:13 PM, Zubair Quraishi  wrote:
> 
> > My repositories in project.clj looks like this:
> 
> >
> 
> >
> 
> >
> 
> >   :repositories {"sonatype-oss-public"
> 
> >
> 
> >                  "https://oss.sonatype.org/content/groups/public/";
> 
> >
> 
> >
> 
> >
> 
> >                  "aa"
> 
> >
> 
> >                  "https://clojars.org/org.om/om"}
> 
> >
> 
> >
> 
> >
> 
> > On Saturday, January 24, 2015 at 7:23:34 AM UTC+1, Oliver George wrote:
> 
> >
> 
> > > Just a quick sanity check... did you include the "org" bit.  That's new.
> 
> >
> 
> > >
> 
> >
> 
> >
> 
> >
> 
> > > On 24 Jan 2015 17:21, "Zubair Quraishi"  wrote:
> 
> >
> 
> > > I tried that but it still didn't work:
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > > Could not find artifact om:om:jar:0.8.1 in sonatype-oss-public 
> > > (https://clojars.org/org.om/om)
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > > On Saturday, January 24, 2015 at 7:15:57 AM UTC+1, Oliver George wrote:
> 
> >
> 
> > >
> 
> >
> 
> > > > https://clojars.org/org.om/om
> 
> >
> 
> > >
> 
> >
> 
> > > >
> 
> >
> 
> > >
> 
> >
> 
> > > > I think david may change the group id again based on what i can see in 
> > > > the om repo so keep your eyes open but this will work today for 0.8.1
> 
> >
> 
> > >
> 
> >
> 
> > > >
> 
> >
> 
> > >
> 
> >
> 
> > > > On 24 Jan 2015 17:05, "Zubair Quraishi"  wrote:
> 
> >
> 
> > >
> 
> >
> 
> > > > When I try to include Om 0.8.1 I get the following error:
> 
> >
> 
> > >
> 
> >
> 
> > > >
> 
> >
> 
> > >
> 
> >
> 
> > > >
> 
> >
> 
> > >
> 
> >
> 
> > >

Re: [ClojureScript] Can't find Om 0.8.1

2015-01-24 Thread Zubair Quraishi
MMM, I took a look at your project.clj, I see there are no repos defined. I 
tried removing them from my project.clj but I still get:

Could not find artifact om:om:jar:0.8.1 in central 
(http://repo1.maven.org/maven2/)
Could not find artifact om:om:jar:0.8.1 in clojars (https://clojars.org/repo/)


On Saturday, January 24, 2015 at 9:21:24 AM UTC+1, Oliver George wrote:
> Here's how I depend on om 0.8.1...
> 
> 
> 
> 
> https://gist.github.com/olivergeorge/ebc5b5f37132fd90d1ea#file-project-clj-L14
> 
> 
> 
> (Someone else might need to comment on :repositories side of things)
> 
> 
> 
> 
> On Sat, Jan 24, 2015 at 7:13 PM, Zubair Quraishi  wrote:
> My repositories in project.clj looks like this:
> 
> 
> 
>   :repositories {"sonatype-oss-public"
> 
>                  "https://oss.sonatype.org/content/groups/public/";
> 
> 
> 
>                  "aa"
> 
>                  "https://clojars.org/org.om/om"}
> 
> 
> 
> On Saturday, January 24, 2015 at 7:23:34 AM UTC+1, Oliver George wrote:
> 
> > Just a quick sanity check... did you include the "org" bit.  That's new.
> 
> >
> 
> 
> 
> > On 24 Jan 2015 17:21, "Zubair Quraishi"  wrote:
> 
> > I tried that but it still didn't work:
> 
> >
> 
> >
> 
> >
> 
> > Could not find artifact om:om:jar:0.8.1 in sonatype-oss-public 
> > (https://clojars.org/org.om/om)
> 
> >
> 
> >
> 
> >
> 
> > On Saturday, January 24, 2015 at 7:15:57 AM UTC+1, Oliver George wrote:
> 
> >
> 
> > > https://clojars.org/org.om/om
> 
> >
> 
> > >
> 
> >
> 
> > > I think david may change the group id again based on what i can see in 
> > > the om repo so keep your eyes open but this will work today for 0.8.1
> 
> >
> 
> > >
> 
> >
> 
> > > On 24 Jan 2015 17:05, "Zubair Quraishi"  wrote:
> 
> >
> 
> > > When I try to include Om 0.8.1 I get the following error:
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > > Could not find artifact om:om:jar:0.8.1 in central 
> > > (http://repo1.maven.org/maven2/)
> 
> >
> 
> > >
> 
> >
> 
> > > Could not find artifact om:om:jar:0.8.1 in clojars 
> > > (https://clojars.org/repo/)
> 
> >
> 
> > >
> 
> >
> 
> > > Could not find artifact om:om:jar:0.8.1 in sonatype-oss-public 
> > > (https://oss.sonatype.org/content/groups/public/)
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > > Any suggestions?
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > >
> 
> >
> 
> > > --
> 
> >
> 
> > >
> 
> >
> 
> > > Note that posts from new members are moderated - please be patient with 
> > > your first post.
> 
> >
> 
> > >
> 
> >
> 
> > > ---
> 
> >
> 
> > >
> 
> >
> 
> > > You received this message because you are subscribed to the Google Groups 
> > > "ClojureScript" group.
> 
> >
> 
> > >
> 
> >
> 
> > > To unsubscribe from this group and stop receiving emails from it, send an 
> > > email to clojurescrip...@googlegroups.com.
> 
> >
> 
> > >
> 
> >
> 
> > > To post to this group, send email to clojur...@googlegroups.com.
> 
> >
> 
> > >
> 
> >
> 
> > > Visit this group at http://groups.google.com/group/clojurescript.
> 
> >
> 
> >
> 
> >
> 
> > I trie
> 
> >
> 
> >
> 
> >
> 
> > --
> 
> >
> 
> > Note that posts from new members are moderated - please be patient with 
> > your first post.
> 
> >
> 
> > ---
> 
> >
> 
> > You received this message because you are subscribed to the Google Groups 
> > "ClojureScript" group.
> 
> >
> 
> > To unsubscribe from this group and stop receiving emails from it, send an 
> > email to clojurescrip...@googlegroups.com.
> 
> >
> 
> > To post to this group, send email to clojur...@googlegroups.com.
> 
> >
> 
> > Visit this group at http://groups.google.com/group/clojurescript.
> 
> 
> 
> --
> 
> Note that posts from new members are moderated - please be patient with your 
> first post.
> 
> ---
> 
> You received this message because you are subscribed to the Google Groups 
> "ClojureScript" group.
> 
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to clojurescrip...@googlegroups.com.
> 
> To post to this group, send email to clojur...@googlegroups.com.
> 
> Visit this group at http://groups.google.com/group/clojurescript.
> 
> 
> 
> 
> 
> -- 
> 
> 
> Oliver George
> Director, Condense
> 0428 740 978

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


Re: [ClojureScript] Can't find Om 0.8.1

2015-01-24 Thread Zubair Quraishi
My repositories in project.clj looks like this:

  :repositories {"sonatype-oss-public"
 "https://oss.sonatype.org/content/groups/public/";
 
 "aa"
 "https://clojars.org/org.om/om"}

On Saturday, January 24, 2015 at 7:23:34 AM UTC+1, Oliver George wrote:
> Just a quick sanity check... did you include the "org" bit.  That's new.
> 
> On 24 Jan 2015 17:21, "Zubair Quraishi"  wrote:
> I tried that but it still didn't work:
> 
> 
> 
> Could not find artifact om:om:jar:0.8.1 in sonatype-oss-public 
> (https://clojars.org/org.om/om)
> 
> 
> 
> On Saturday, January 24, 2015 at 7:15:57 AM UTC+1, Oliver George wrote:
> 
> > https://clojars.org/org.om/om
> 
> >
> 
> > I think david may change the group id again based on what i can see in the 
> > om repo so keep your eyes open but this will work today for 0.8.1
> 
> >
> 
> > On 24 Jan 2015 17:05, "Zubair Quraishi"  wrote:
> 
> > When I try to include Om 0.8.1 I get the following error:
> 
> >
> 
> >
> 
> >
> 
> > Could not find artifact om:om:jar:0.8.1 in central 
> > (http://repo1.maven.org/maven2/)
> 
> >
> 
> > Could not find artifact om:om:jar:0.8.1 in clojars 
> > (https://clojars.org/repo/)
> 
> >
> 
> > Could not find artifact om:om:jar:0.8.1 in sonatype-oss-public 
> > (https://oss.sonatype.org/content/groups/public/)
> 
> >
> 
> >
> 
> >
> 
> > Any suggestions?
> 
> >
> 
> >
> 
> >
> 
> > --
> 
> >
> 
> > Note that posts from new members are moderated - please be patient with 
> > your first post.
> 
> >
> 
> > ---
> 
> >
> 
> > You received this message because you are subscribed to the Google Groups 
> > "ClojureScript" group.
> 
> >
> 
> > To unsubscribe from this group and stop receiving emails from it, send an 
> > email to clojurescrip...@googlegroups.com.
> 
> >
> 
> > To post to this group, send email to clojur...@googlegroups.com.
> 
> >
> 
> > Visit this group at http://groups.google.com/group/clojurescript.
> 
> 
> 
> I trie
> 
> 
> 
> --
> 
> Note that posts from new members are moderated - please be patient with your 
> first post.
> 
> ---
> 
> You received this message because you are subscribed to the Google Groups 
> "ClojureScript" group.
> 
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to clojurescrip...@googlegroups.com.
> 
> To post to this group, send email to clojur...@googlegroups.com.
> 
> Visit this group at http://groups.google.com/group/clojurescript.

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


Re: [ClojureScript] Can't find Om 0.8.1

2015-01-23 Thread Zubair Quraishi
I tried that but it still didn't work:

Could not find artifact om:om:jar:0.8.1 in sonatype-oss-public 
(https://clojars.org/org.om/om)

On Saturday, January 24, 2015 at 7:15:57 AM UTC+1, Oliver George wrote:
> https://clojars.org/org.om/om
> 
> I think david may change the group id again based on what i can see in the om 
> repo so keep your eyes open but this will work today for 0.8.1
> 
> On 24 Jan 2015 17:05, "Zubair Quraishi"  wrote:
> When I try to include Om 0.8.1 I get the following error:
> 
> 
> 
> Could not find artifact om:om:jar:0.8.1 in central 
> (http://repo1.maven.org/maven2/)
> 
> Could not find artifact om:om:jar:0.8.1 in clojars (https://clojars.org/repo/)
> 
> Could not find artifact om:om:jar:0.8.1 in sonatype-oss-public 
> (https://oss.sonatype.org/content/groups/public/)
> 
> 
> 
> Any suggestions?
> 
> 
> 
> --
> 
> Note that posts from new members are moderated - please be patient with your 
> first post.
> 
> ---
> 
> You received this message because you are subscribed to the Google Groups 
> "ClojureScript" group.
> 
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to clojurescrip...@googlegroups.com.
> 
> To post to this group, send email to clojur...@googlegroups.com.
> 
> Visit this group at http://groups.google.com/group/clojurescript.

I trie

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Can't find Om 0.8.1

2015-01-23 Thread Zubair Quraishi
When I try to include Om 0.8.1 I get the following error:

Could not find artifact om:om:jar:0.8.1 in central 
(http://repo1.maven.org/maven2/)
Could not find artifact om:om:jar:0.8.1 in clojars (https://clojars.org/repo/)
Could not find artifact om:om:jar:0.8.1 in sonatype-oss-public 
(https://oss.sonatype.org/content/groups/public/)

Any suggestions?

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: How do we do authentification in a Om app?

2015-01-22 Thread Zubair Quraishi
On Wednesday, January 21, 2015 at 5:54:28 PM UTC+1, Leon Talbot wrote:
> What are good yet simple examples of om app that that implements 
> authentification. 
> 
> Thanks!

I have made authentication in an Om app. You first have to definie what level 
of Authentication you want as they are all handled in very different ways:

- username/password
- facebook client side
- facebook server side
- linkedin client side 
- linkedin server side

etc... The simplest case is username password, which you implement using a 
"session", which again has issues, whether you wish to use cookies, or no 
cookies.  If you can give the use cases you need then I can walk you through 
making this in Om

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Would anyone like to make a video interview about Light Table / Clojurescript with me?

2015-01-22 Thread Zubair Quraishi
Hi,

Would anyone like to make a video interview about Light Table / Clojurescript 
with me? I have already made some videos (just screencasts really) about 
Clojurescript and LightTable, but it has been a while since I made the last 
one. Would anyone like to make a video with me about their project or some 
feature of LightTable / Clojurescript? It can be published as the next episode? 
Here are the current videos:

http://www.zubairquraishi.com/zubairquraishi/clojurescript--light-table.html

We could do the interview/video over skype, and we could optionally use some 
screen recording software to show your screen too? My aim is not commercial, 
but just to learn Light Table and Clojurescript better. My current sticking 
point is tranducers by the way, which I just cannot get my head around, but any 
topics are welcome as I am not that good at Clojure/Clojurescript, I just 
muddle along somehow :)

Thanks
Zubair

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: Organization of project file for multiple single-page apps

2014-09-09 Thread Zubair Quraishi
Sorry, seems like I misunderstood. You have several projects in one file, not 
several profiles, is that correct?


On Tuesday, September 9, 2014 12:21:05 PM UTC+2, Jonathon McKitrick wrote:
> I have about 6 pages with their own cljs code, and I'd also like to have dev, 
> pre-prod, and prod compilation settings.
> 
> What's the best way to organize the project file to do this?
> 
> I currently have something like this:
> 
> :cljsbuild {:builds
>   {:outlines
>{:source-paths ["src/cljs/outlines"] ;;"test/cljs"
> :compiler {:output-to "resources/public/js/outlines.js"
>:optimizations :simple
>:pretty-print true
>:preamble ["reagent/react.js"]}}
>:speakers
>{:source-paths ["src/cljs/speakers"]
> :compiler {:output-to "resources/public/js/speakers.js"
>:optimizations :simple
>:pretty-print true
>:preamble ["reagent/react.js"]}}
>:outgoing
>{:source-paths ["src/cljs/outgoing"]
> :compiler {:output-to "resources/public/js/outgoing.js"
>:optimizations :simple
>:pretty-print true
>:preamble ["reagent/react.js"]}}
>:incoming
>{:source-paths ["src/cljs/incoming"]
> :compiler {:output-to "resources/public/js/incoming.js"
>:externs ["js/externs.js"]
>:optimizations :advanced
>:pretty-print false
>;;:output-dir "resources/public/js"
>;;:source-map "resources/public/js/incoming.js.map"
>:preamble ["jquery/jquery-2.1.1.min.js" 
> "reagent/react.js"]}}
>:home
>{:source-paths ["src/cljs/home"]
> :compiler {:output-to "resources/public/js/home.js"
>:optimizations :simple
>:pretty-print true
>:preamble ["reagent/react.js"]}}
>:confirm
>{:source-paths ["src/cljs/confirm"]
> :compiler {:output-to "resources/public/js/confirm.js"
>:optimizations :simple
>:pretty-print true
>:preamble ["reagent/react.js"]}}
>#_:outlines-testing
>#_{:source-paths ["test/cljs" "src/cljs/outlines"]
> :compiler {:preamble ["jquery/jquery-2.1.1.min.js" 
> "reagent/react.js"]
>:output-to 
> "resources/public/js/outlines-testing.js"
>:optimizations :simple
>:pretty-print true}}}
>   #_:test-commands #_{"outlines-testing"
>   ["phantomjs" :runner "resources/polyfill.js" 
> "resources/public/js/outlines-testing.js"]}}

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: Organization of project file for multiple single-page apps

2014-09-09 Thread Zubair Quraishi
You have it pretty much right, this is my project clj for Coils:

https://github.com/zubairq/coils/blob/master/project.clj

 :profiles {
 :dev
 {
  :source-paths ["src" "../srcdev"]
  :cljsbuild
  {
   :builds
   [
{
 :source-paths ["src"]
 :compiler {
:output-to  "resources/public/main.js"
:optimizations  :whitespace
:output-wrapper false
:externs
["resources/public/google_maps_api_v3_11.js"]
:pretty-print   false
}
 }
]

   }
  }

 :base
 {
  :source-paths ["src"
 "srcbase"
 ]
  :cljsbuild
  {
   :builds
   [
{
 :source-paths ["src"]
 :compiler {
:output-to  "resources/public/main.js"
:optimizations  :whitespace
:output-wrapper false
:externs
["resources/public/jquery-externs.js"
 
"resources/public/google_maps_api_v3_11.js"]
:pretty-print   false
}
 }
]

   }
  }


 :test
 {
  :source-paths ["src" "../srctest"]
  :cljsbuild
  {
   :builds
   [
{
 :source-paths ["src"]
 :compiler {
:output-to  "resources/public/main.js"
:optimizations  :advanced
:output-wrapper false
:externs
["resources/public/jquery-externs.js"
 
"resources/public/google_maps_api_v3_11.js"
 
"resources/public/reactextern.js"]
:pretty-print   false
:foreign-libs [{:file 
"https://maps.googleapis.com/maps/api/js?sensor=false";
:provides  ["google.maps" 
"google.maps.MapTypeId"]}]
}
 }
]

   }
  }

 :prod
 {
  :source-paths ["src" "../srcprod"]
  :cljsbuild
  {
   :builds
   [
{
 :source-paths ["src"]
 :compiler {
:output-to  "resources/public/main.js"
:optimizations  :advanced
:output-wrapper false
:externs
["resources/public/jquery-externs.js"
 
"resources/public/google_maps_api_v3_11.js"
 
"resources/public/reactextern.js"]
:pretty-print   false
:foreign-libs [{:file 
"https://maps.googleapis.com/maps/api/js?sensor=false";
:provides  ["google.maps" 
"google.maps.MapTypeId"]}]
}
 }
]

   }
  }

On Tuesday, September 9, 2014 12:21:05 PM UTC+2, Jonathon McKitrick wrote:
> I have about 6 pages with their own cljs code, and I'd also like to have dev, 
> pre-prod, and prod compilation settings.
> 
> What's the best way to organize the project file to do this?
> 
> I currently have something like this:
> 
> :cljsbuild {:builds
>   {:outlines
>{:source-paths ["src/cljs/outlines"] ;;"test/cljs"
> :compiler {:output-to "resources/public/js/outlines.js"
>:optimizations :simple
>:pretty-print true
>:preamble ["reagent/react.js"]}}
>:speakers
>{:source-paths ["src/cljs/speakers"]
> :compiler {:output-to "resources/public/js/speakers.js"
>:optimizations :simple
>:pretty-print true
>:preamble ["reagent/react.js"]}}
>:outgoing
>{:source-paths ["src/cljs/outgoing"]
> :compiler {:output-to "resources/public/js/outgoing.js"
>   

Re: [ClojureScript] Can I make any updates to a Clojurescript Om component in the InitState?

2014-09-08 Thread Zubair Quraishi
On Sunday, September 7, 2014 6:20:55 AM UTC+2, Chris Jones wrote:
> On Saturday, September 6, 2014 11:40:04 AM UTC-7, Zubair Quraishi wrote:
> > I am updating the top most item, so it has no parent in that way.Ok, so if 
> > use IWillMount how can I tell whether it is in render state or not?
> 
> IWillMount is the way to go. The 'rendering?' function will tell you if React 
> is currently in a rendering phase.
> https://github.com/swannodette/om/wiki/Documentation#rendering

That is perfect, thanks! I will try the "rendering?" function

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


Re: [ClojureScript] Can I make any updates to a Clojurescript Om component in the InitState?

2014-09-06 Thread Zubair Quraishi
I am updating the top most item, so it has no parent in that way.Ok, so if use 
IWillMount how can I tell whether it is in render state or not? 

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Can I make any updates to a Clojurescript Om component in the InitState?

2014-09-05 Thread Zubair Quraishi
I have some updates to app state which are called in the IInitState method, but 
they could occur during or out of the render phase. How should I do this? (The 
updates are called via channels, sometimes out of the render phase)

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: Update clojurescript atom from javascript

2014-08-23 Thread Zubair Quraishi
On Thursday, August 21, 2014 2:16:01 PM UTC+1, upgrad...@gmail.com wrote:
> Hi all, I'm sure I could figure this out, but I'm feeling lazy: Is it 
> possible to update a clojurescript atom from javascript? If so, what's the 
> syntax?
> 
> Thanks, 
> Dave

yes, you can. create a function in clojurescript as an extern function which 
updates the atom, passing in the value you want to update the atom with, then 
just call the clojurescript function from javascript

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: DevArt Co(de)Factory open source release

2014-08-23 Thread Zubair Quraishi
So does this mean that Google is experimenting with Clojurescript then?

On Wednesday, August 20, 2014 1:31:13 PM UTC+1, Karsten Schmidt wrote:
> Hi fellow Clojurians,
> 
> 
> 
> it's my absolute pleasure to finally announce the open source release
> 
> of an art project I've been working on full-time since beginning of
> 
> the year:
> 
> 
> 
> DevArt Co(de)Factory is a joint commission by Google and the Barbican
> 
> Centre London and is featured as part of DevArt at the Digital
> 
> Revolutions exhibition, currently on show at the Barbican until
> 
> September 19.
> 
> 
> 
> Co(de)Factory is an installation & online design tool allowing
> 
> visitors to create abstract 3D sculptures using code operations
> 
> assembled with a visual programming tool and get the chance to have
> 
> their piece 3D printed on an open source SLA printer, which is part of
> 
> the exhibit. Furthermore, any artefacts in the online gallery can be
> 
> edited further by others, thus forming chains of co-authorship.
> 
> 
> 
> Project website:
> 
> http://devartcodefactory.com/
> 
> 
> 
> Repository (incl. all source, assets, fabrication files, sketches):
> 
> http://github.com/postspectacular/devart-codefactory
> 
> 
> 
> The project was almost entirely (99%) developed in
> 
> Clojure/ClojureScript and counts 5400+ LOC for just the Web UI /
> 
> AppEngine backend (plus ~10K LOC in separately written libraries). The
> 
> UI heavily uses core.async's pub-sub bus for most of its internal
> 
> comms. The release also includes a sub-project related to the
> 
> generation of 3D printed assets for one of the largest SLA printed
> 
> structures so far (2.4 x 3.0 metres), and clocks in with another 800+
> 
> LOC.
> 
> 
> 
> It was a huge challenge (or rather opportunity) to put CLJ(S) to the
> 
> test and use it for scenarios (computational / generative design),
> 
> which aren't often talked about in the Clojure community and for which
> 
> there were hardly any (suitable) prior solutions or libraries
> 
> available and hence had to be developed from scratch. Much of that
> 
> development had already started to happen previously in an isolated
> 
> manner under the http://thi.ng umbrella to slowly build up a
> 
> collection of libraries with a mutual focus on geometry, mesh
> 
> processing, rendering & visualization tasks. In fact, this project, as
> 
> the first publicly available use case of many thi.ng libs, IMHO proves
> 
> that our beloved language(s) is also super nice to work with in these
> 
> contexts (just in case anyone had doubts :).
> 
> 
> 
> Feel free to send me an email or reply here if you'd like to know
> 
> more... Happy to answer any questions. Also happy about any
> 
> Clojure job offers on projects of similar nature :)
> 
> 
> 
> Well, I hope some of you find this release useful & educational.
> 
> 
> 
> All my best, K.
> 
> --
> 
> Karsten Schmidt
> 
> 
> 
> w: http://postspectacular.com
> 
> w: http://thi.ng/
> 
> w: http://toxiclibs.org

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: I thinking using Om + Kioo or Enfocus, and I'm wondering: are these good for SEO?

2014-08-20 Thread Zubair Quraishi
On Thursday, August 21, 2014 4:17:24 AM UTC+1, Leon Talbot wrote:
> Le mercredi 20 août 2014 12:07:55 UTC-4, Robert Stuttaford a écrit :
> 
> > On Tuesday, August 19, 2014 4:04:48 AM UTC+2, Leon Talbot wrote:
> 
> > > Thank you for your reply.
> 
> > 
> 
> > Google has started executing JavaScript now.
> 
> > 
> 
> > http://googlewebmastercentral.blogspot.com/2014/05/understanding-web-pages-better.html
> 
> > 
> 
> > You might want to try building something with Om / Reagent / Quiescent + 
> > Sablono / Kioo and see how well Google indexes it. You can always render it 
> > on the server so long, see:
> 
> > 
> 
> > https://github.com/DomKM/omelette
> 
> > Writeup: http://domkm.com/posts/2014-06-15-isomorphic-clojure-1/
> 
> 
> 
> Thanks a lot! I've enjoyed reading the writeup.

Hi Leon, 
 Yes you can render Om from the server, and google has started experimental 
ajax caching but both are not tried and tested yet. My advice is that if you 
are earning money on this new website to use Ember or Ruby on Rails, as they 
excel at generating server side HTML and delivering it in a google freindly 
way, much better than Clojure or Clojurescript at the moment. Use the right 
tool for the job!
Zubair

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: I thinking using Om + Kioo or Enfocus, and I'm wondering: are these good for SEO?

2014-08-20 Thread Zubair Quraishi
On Wednesday, August 20, 2014 2:02:09 AM UTC+1, Leon Talbot wrote:
> Le mardi 19 août 2014 08:52:58 UTC-4, Zubair Quraishi a écrit :
> 
> > No, if you use Om you will either have to render from the server, otherwise 
> > it willbe terrible for SEO, as AJAX updates are not very useful for SEO 
> > since google does not index them in the same way as static sites.
> 
> 
> 
> Thanks for your answer. Would you have the same answer for Enfocus?

Yes, you will have the same problem with Enfocus. This is because Enfocus 
updates the DOM after the initial HTML page load, and google indexes the DOM 
content on the initial page load, not on the AJAX updates that happen 
afterwards (they are trying to figure out a way to do this but it doesn't work 
yet, as they have been trying for several years)

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: I thinking using Om + Kioo or Enfocus, and I'm wondering: are these good for SEO?

2014-08-19 Thread Zubair Quraishi
No, if you use Om you will either have to render from the server, otherwise it 
willbe terrible for SEO, as AJAX updates are not very useful for SEO since 
google does not index them in the same way as static sites.

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


Re: [ClojureScript] Re: New visual debugger added to Coils Om framework

2014-08-12 Thread Zubair Quraishi
http://lexical.foobar.systems/ seems to work, 
http://lexical.foobar.systems/rdp.html had some weird redirect stuff going on 
but even that seems to work now.

Thanks I'll read through them

On Tuesday, August 12, 2014 1:00:18 PM UTC+2, Harsha wrote:
> That's weird. I clicked and it worked.
> 
> I use github pages
> 
> 
> 
> no 25 on ---  http://lexical.foobar.systems/
> 
> 
> 
> It could be that the router is rejecting the domain name.
> 
> 
> 
> 
> 
> 
> 
> On Tue, Aug 12, 2014 at 3:22 PM, Zubair Quraishi  wrote:
> 
> > I couldn't get the :
> 
> >
> 
> > http://lexical.foobar.systems/rdp.html
> 
> >
> 
> > :link to work
> 
> >
> 
> > On Monday, August 11, 2014 6:40:08 PM UTC+2, Harsha wrote:
> 
> >> Documentation is definitely a weak point.
> 
> >>
> 
> >> Trying to do some literate programming style documentation :)
> 
> >>
> 
> >>
> 
> >>
> 
> >> I call this model, Reactive Data Processing (RDP).
> 
> >>
> 
> >>
> 
> >>
> 
> >> Design Influences are listed at -- http://lexical.foobar.systems/rdp.html
> 
> >>
> 
> >> Feel free to go through the repo -- https://github.com/harsha-mudi/rdp
> 
> >>
> 
> >>
> 
> >>
> 
> >> The only interesting thing I did was to make an abstraction called System.
> 
> >>
> 
> >> Everything follows from there.
> 
> >>
> 
> >>
> 
> >>
> 
> >> This model is build on OOPy ideas so it should be compatible with most
> 
> >>
> 
> >> langs out there. I actually use React.js in my app so om should not be
> 
> >>
> 
> >> that difficult to adapt to.
> 
> >>
> 
> >>
> 
> >>
> 
> >> Currently om doesn't have best practices wrt the number of core.async
> 
> >>
> 
> >> channels to have, or how to design components. That's a place where
> 
> >>
> 
> >> RDP like ideas can help. I suspect the clojurescript port of RDP would
> 
> >>
> 
> >> be like 5 protocols. I am waiting for the js to be stable before I go
> 
> >>
> 
> >> for that.
> 
> >>
> 
> >>
> 
> >>
> 
> >> High level approaches talk about composability, higher order algebra
> 
> >>
> 
> >> and  and I talk about systems and wires :)
> 
> >>
> 
> >>
> 
> >>
> 
> >> ---
> 
> >>
> 
> >> www.foobar.systems
> 
> >>
> 
> >>
> 
> >>
> 
> >>
> 
> >>
> 
> >> On Mon, Aug 11, 2014 at 12:32 PM, Zubair Quraishi  
> >> wrote:
> 
> >>
> 
> >> > On Friday, August 8, 2014 7:20:41 PM UTC+2, Harsha wrote:
> 
> >>
> 
> >> >> Hi,
> 
> >>
> 
> >> >>
> 
> >>
> 
> >> >>
> 
> >>
> 
> >> >>
> 
> >>
> 
> >> >> https://github.com/harsha-mudi/esti -- that's the app
> 
> >>
> 
> >> >>
> 
> >>
> 
> >> >>
> 
> >>
> 
> >> >>
> 
> >>
> 
> >> >> That's the debugger as a mixin,
> 
> >>
> 
> >> >>
> 
> >>
> 
> >> >> https://github.com/harsha-mudi/rdp/blob/master/lib/debugger.js
> 
> >>
> 
> >> >>
> 
> >>
> 
> >> >> The ui of the debugger is in the esti app again.
> 
> >>
> 
> >> >>
> 
> >>
> 
> >> >>
> 
> >>
> 
> >> >>
> 
> >>
> 
> >> >> Debugging and Syncing are just a side-effect of designing the
> 
> >>
> 
> >> >>
> 
> >>
> 
> >> >> application around reactive components.
> 
> >>
> 
> >> >>
> 
> >>
> 
> >> >>
> 
> >>
> 
> >> >>
> 
> >>
> 
> >> >> To put it in om's terms, every component ( I use the word System ) in
> 
> >>
> 
> >> >>
> 
> >>
> 
> >> >> my framework comes with at-least 5 channels.
> 
> >>
> 
> >> >>
> 
> >>
> 
> >> >>
> 
> >>
> 
> >> >&

Re: [ClojureScript] Re: New visual debugger added to Coils Om framework

2014-08-12 Thread Zubair Quraishi
I couldn't get the :

http://lexical.foobar.systems/rdp.html 

:link to work

On Monday, August 11, 2014 6:40:08 PM UTC+2, Harsha wrote:
> Documentation is definitely a weak point.
> 
> Trying to do some literate programming style documentation :)
> 
> 
> 
> I call this model, Reactive Data Processing (RDP).
> 
> 
> 
> Design Influences are listed at -- http://lexical.foobar.systems/rdp.html
> 
> Feel free to go through the repo -- https://github.com/harsha-mudi/rdp
> 
> 
> 
> The only interesting thing I did was to make an abstraction called System.
> 
> Everything follows from there.
> 
> 
> 
> This model is build on OOPy ideas so it should be compatible with most
> 
> langs out there. I actually use React.js in my app so om should not be
> 
> that difficult to adapt to.
> 
> 
> 
> Currently om doesn't have best practices wrt the number of core.async
> 
> channels to have, or how to design components. That's a place where
> 
> RDP like ideas can help. I suspect the clojurescript port of RDP would
> 
> be like 5 protocols. I am waiting for the js to be stable before I go
> 
> for that.
> 
> 
> 
> High level approaches talk about composability, higher order algebra
> 
> and  and I talk about systems and wires :)
> 
> 
> 
> ---
> 
> www.foobar.systems
> 
> 
> 
> 
> 
> On Mon, Aug 11, 2014 at 12:32 PM, Zubair Quraishi  wrote:
> 
> > On Friday, August 8, 2014 7:20:41 PM UTC+2, Harsha wrote:
> 
> >> Hi,
> 
> >>
> 
> >>
> 
> >>
> 
> >> https://github.com/harsha-mudi/esti -- that's the app
> 
> >>
> 
> >>
> 
> >>
> 
> >> That's the debugger as a mixin,
> 
> >>
> 
> >> https://github.com/harsha-mudi/rdp/blob/master/lib/debugger.js
> 
> >>
> 
> >> The ui of the debugger is in the esti app again.
> 
> >>
> 
> >>
> 
> >>
> 
> >> Debugging and Syncing are just a side-effect of designing the
> 
> >>
> 
> >> application around reactive components.
> 
> >>
> 
> >>
> 
> >>
> 
> >> To put it in om's terms, every component ( I use the word System ) in
> 
> >>
> 
> >> my framework comes with at-least 5 channels.
> 
> >>
> 
> >>
> 
> >>
> 
> >> "sysin", "sysout", "syserr", "feedback", "debug"
> 
> >>
> 
> >>
> 
> >>
> 
> >> ( that's a simplistic explanation because I got inspired by low level
> 
> >>
> 
> >> electronics
> 
> >>
> 
> >>   for the most part )
> 
> >>
> 
> >>
> 
> >>
> 
> >> Since all communication to the component happens trough these channels,
> 
> >>
> 
> >> a debugger is just something that sits in-between.
> 
> >>
> 
> >>
> 
> >>
> 
> >> I really wanted to make a phonegap app, but I lost my phone.
> 
> >>
> 
> >> nodewebkit seemed like the next best thing given that LightTable uses it.
> 
> >>
> 
> >>
> 
> >>
> 
> >> I am working on runtime debugging.
> 
> >>
> 
> >> Currently the debugger is enabled by the build step.
> 
> >>
> 
> >>
> 
> >>
> 
> >> `npm bin`/squareboy esti.tasklist.coffee --stepper --sys "clicks" --tracer
> 
> >>
> 
> >>
> 
> >>
> 
> >> I have added a macosx binary -- 
> >> https://github.com/harsha-mudi/esti/releases
> 
> >>
> 
> >> and clarified the Readme a bit.
> 
> >>
> 
> >>
> 
> >>
> 
> >> I have compiled it using --stepper --sys "clicks" and --tracer, so you
> 
> >>
> 
> >> should see the step button. Try adding a task. You should get some
> 
> >>
> 
> >> kinda display.
> 
> >>
> 
> >>
> 
> >>
> 
> >> In nodewebkit, the developer tools is located on the top right corner.
> 
> >>
> 
> >> My favourite part is actually the tons and tons of tracing.
> 
> >>
> 
> >>
> 
> >>
> 
> >> On Fri, Aug 8, 2014 at 7:25 PM, Zubair Quraishi  wrote:
> 
> >>
> 
> >> > It uses macros, core.async go blocks and observers over shared atoms to 
> >> > get the debug information
> 
> >>

Re: [ClojureScript] Re: New visual debugger added to Coils Om framework

2014-08-11 Thread Zubair Quraishi
On Friday, August 8, 2014 7:20:41 PM UTC+2, Harsha wrote:
> Hi,
> 
> 
> 
> https://github.com/harsha-mudi/esti -- that's the app
> 
> 
> 
> That's the debugger as a mixin,
> 
> https://github.com/harsha-mudi/rdp/blob/master/lib/debugger.js
> 
> The ui of the debugger is in the esti app again.
> 
> 
> 
> Debugging and Syncing are just a side-effect of designing the
> 
> application around reactive components.
> 
> 
> 
> To put it in om's terms, every component ( I use the word System ) in
> 
> my framework comes with at-least 5 channels.
> 
> 
> 
> "sysin", "sysout", "syserr", "feedback", "debug"
> 
> 
> 
> ( that's a simplistic explanation because I got inspired by low level
> 
> electronics
> 
>   for the most part )
> 
> 
> 
> Since all communication to the component happens trough these channels,
> 
> a debugger is just something that sits in-between.
> 
> 
> 
> I really wanted to make a phonegap app, but I lost my phone.
> 
> nodewebkit seemed like the next best thing given that LightTable uses it.
> 
> 
> 
> I am working on runtime debugging.
> 
> Currently the debugger is enabled by the build step.
> 
> 
> 
> `npm bin`/squareboy esti.tasklist.coffee --stepper --sys "clicks" --tracer
> 
> 
> 
> I have added a macosx binary -- https://github.com/harsha-mudi/esti/releases
> 
> and clarified the Readme a bit.
> 
> 
> 
> I have compiled it using --stepper --sys "clicks" and --tracer, so you
> 
> should see the step button. Try adding a task. You should get some
> 
> kinda display.
> 
> 
> 
> In nodewebkit, the developer tools is located on the top right corner.
> 
> My favourite part is actually the tons and tons of tracing.
> 
> 
> 
> On Fri, Aug 8, 2014 at 7:25 PM, Zubair Quraishi  wrote:
> 
> > It uses macros, core.async go blocks and observers over shared atoms to get 
> > the debug information
> 
> 
> 
> Yes, that's a very interesting place to put a debugger. Om components
> 
> change when the atoms change so you can easily put it there.

I took a more detailed look. I especially like that you took the inspiration 
from electronics. Let me know if you blog about this

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: New visual debugger added to Coils Om framework

2014-08-08 Thread Zubair Quraishi
Hi Harsha,
 I watched the videos in the eat. Seems like you have realtime sync in place 
like meteor, cool! :)
Zubair

On Friday, August 8, 2014 10:12:14 AM UTC+2, Harsha wrote:
> On Thursday, August 7, 2014 11:06:12 PM UTC+5:30, Zubair Quraishi wrote:
> > I add a new feature so that the current Om component being debugged in the 
> > "render" phase now shows in the debugger.  So when you click on "Debug" and 
> > then see the debug items on the right you will see GUI fragments of the 
> > current Om component, its code (in coils form) and the state passed into 
> > that component:
> > 
> > http://connecttous.co/connecttous/connecttous.html?livedebug=true
> 
> This is neat.
> I have done something very similar with my framework, harsha-mudi/rdp.
> 
> It's an important advantage you get because of modelling everything
> on top of events and messaging.
> 
> From an implementation perspective, I think the right way to approach this
> would be mixins. I am not sure how mixins are done in clojurescript.
> 
> For example, from the ui you could take a component's name and
> apply debugging methods to that component with a mixin. This like
> applying a breakpoint.
> 
> I believe you have applied debugging at a channel level ?

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: New visual debugger added to Coils Om framework

2014-08-08 Thread Zubair Quraishi
Hi Harsha,
 I took a look at your framework, but I could not get the debugger to work. Is 
this the correct URL?

https://github.com/harsha-mudi/esti

Zubair

PS: It uses macros, core.async go blocks and observers over shared atoms to get 
the debug information. Not so much channels though. Feel free to dig into the 
code and see if you like

On Friday, August 8, 2014 10:12:14 AM UTC+2, Harsha wrote:
> On Thursday, August 7, 2014 11:06:12 PM UTC+5:30, Zubair Quraishi wrote:
> > I add a new feature so that the current Om component being debugged in the 
> > "render" phase now shows in the debugger.  So when you click on "Debug" and 
> > then see the debug items on the right you will see GUI fragments of the 
> > current Om component, its code (in coils form) and the state passed into 
> > that component:
> > 
> > http://connecttous.co/connecttous/connecttous.html?livedebug=true
> 
> This is neat.
> I have done something very similar with my framework, harsha-mudi/rdp.
> 
> It's an important advantage you get because of modelling everything
> on top of events and messaging.
> 
> From an implementation perspective, I think the right way to approach this
> would be mixins. I am not sure how mixins are done in clojurescript.
> 
> For example, from the ui you could take a component's name and
> apply debugging methods to that component with a mixin. This like
> applying a breakpoint.
> 
> I believe you have applied debugging at a channel level ?

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] New visual debugger added to Coils Om framework

2014-08-07 Thread Zubair Quraishi
I add a new feature so that the current Om component being debugged in the 
"render" phase now shows in the debugger.  So when you click on "Debug" and 
then see the debug items on the right you will see GUI fragments of the current 
Om component, its code (in coils form) and the state passed into that component:

http://connecttous.co/connecttous/connecttous.html?livedebug=true

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


Re: [ClojureScript] Update Om demo with time travelling debugger

2014-08-01 Thread Zubair Quraishi
On Wednesday, July 16, 2014 1:50:06 AM UTC+2, Ahmad Hammad wrote:
> This is pretty cool Zubair. Good job.
> 
> I think the client-side debugger would be useful as a standalone library for 
> those who don't want the full framework. How hard would it be to package that 
> separately? I'd be happy to help do that.
> 
> Keep it up.
> 
> Ahmad Hammad

The demo has now been updated with Om 0.7.0 and react 0.11.1:

http://connecttous.co/connecttous/connecttous.html?livedebug=true

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: Send large immutable data structure with a lot of sharing back and forth to the server

2014-07-27 Thread Zubair Quraishi
Glad to help. Let us know how you get on!

On Friday, July 25, 2014 9:38:49 PM UTC+2, Anton Astashov wrote:
> Okay, so seems like the answer is - watch the changes in atom, send these 
> changes to the server, on the server store them unmerged, as a set of 
> separate patches, and when opening a document on the client, just send all 
> that history of patches, and the client will replay them on its side.
> 
> That makes sense. I gonna try to do something like that. Thanks everyone for 
> help!
> 
> On Wednesday, July 23, 2014 10:47:54 AM UTC-7, Anton Astashov wrote:
> > Hello,
> > 
> > Is there any good way to send large immutable data with a lot of structural 
> > sharing (like, app state with undo/redo stack) to the server,
> > and also get it from the server and correctly rebuild it in browser's 
> > memory?
> > 
> > If I just do (clj->js my-data), I will get a JSON, but it will lose the 
> > information about shared data.
> > 
> > So, what would be the best way to handle that? It seems like I need some 
> > way to know what pieces are reused, serialize the data, store reused pieces 
> > as references, and then also being able to deserialize it having that 
> > knowledge.
> > 
> > How do you usually accomplish that?
> > 
> > Thanks!

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: Send large immutable data structure with a lot of sharing back and forth to the server

2014-07-25 Thread Zubair Quraishi
Hi Anton,
 Yes, the change is sent to the server as soon as the change occurs. They could 
also be bunched up and sent when there are say 20k bytes of changes to be sent, 
but I haven't found any performance problems yet, so I haven't had to do that 
yet, but in the future this is very likely how it will work.

To restore the state I just set up the initial state in the browser, an empty 
map, and then read the changes sequentially from the server, which I then assoc 
into the client state. The changes are all handled by atoms in Clojurescript, 
so not much that I have to do except read the changes in the cirrect order and 
apply them. I do however store a timestamp with each change so that it can 
replay the change at exactly the same time as it orginally happened. Try it, 
try moving your mouse in the browser at different speeds and it should play 
back the same.

The playback happens here (note that everything stored in Neo4j on the server). 
The server part to add history:

https://github.com/zubairq/coils/search?q=%28defn+%21add-history&ref=cmdform

:and replaying the session on the client is here:

https://github.com/zubairq/coils/search?q=%28defn+playback-session+%5B%26+%7B%3Akeys&ref=cmdform

Let me know if it helps or if you need more explanation.

Zubair


On Thursday, July 24, 2014 8:17:39 PM UTC+2, Anton Astashov wrote:
> Hi!
> 
> Thanks for answers! :)
> 
> So, Zubair, you send only the change immediately after its occur in the 
> global state to the server. That makes sense, but makes things a bit more 
> difficult. What about restoring the state from the server? How do you build 
> that structure with shared substructures in browser's memory? It basically 
> should be something like creating shared substructures first, and then 
> assigning them here and there in a big global one. Do you do something like 
> that in your framework? If yes, where should I look at?
> 
> Thanks!
> 
> On Wednesday, July 23, 2014 9:28:44 PM UTC-7, Zubair Quraishi wrote:
> > Hi Anton,
> > 
> >  In the Coils framework it does actually share structures (atoms) from the 
> > client to the server, which can then be replayed back to the client again. 
> > An example is at:
> > 
> > http://connecttous.co/
> > 
> > :where you can play around with the sample application, and then you can go 
> > to:
> > 
> > http://connecttous.co/connecttous/connecttous.html?playback=true
> > 
> > : to play back the sessions. The way this is done is by just sending the 
> > updates of the Om Application State to the server (assuming you are using 
> > David Nolen's Om for the client side) using Om's tx-listen. Here is where 
> > the code is:
> > 
> > https://github.com/zubairq/coils/search?q=tx-listen&ref=cmdform
> > 
> > : tx-listen takes two arguments, the first of which contains the changes:
> > 
> >  (fn [tx-data root-cursor]
> > 
> > : so you can do  (:path tx-data) to get just the changes to the GUI, which 
> > is what Coils does, and then it sends those changes to the server. To see 
> > the changes being sent live to the server, if you go to connecttous.co and 
> > do stuff in the GUI, then open the network console, you can see calls to 
> > the server which send the GUI state from client to server, by looking out 
> > for the calls which are something like this:
> > 
> > http://connecttous.co/connecttous/action?systemaction=!add-history¶ms=
> > 
> > :This sends the GUI changes back to the server, which then get stored in 
> > the backend.
> > 
> > 
> > Regarding Andrew Chamber's point about tree diff, Andrew is spot on! In 
> > fact when you do local debugging in Coils:
> > 
> > http://connecttous.co/connecttous/connecttous.html?livedebug=true
> > 
> > : on the right you can see changes to two trees that Coils uses, called UI 
> > and DATA. To show these changes it uses the Clojure diff call:
> > 
> > https://github.com/zubairq/coils/search?q=deleted+%28first+&type=Code
> > 
> > :which shows added and deleted entries from the trees. I hope this helps 
> > and that you can apply something similar to your own project.
> > 
> > Thanks
> > Zubair

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Re: Send large immutable data structure with a lot of sharing back and forth to the server

2014-07-23 Thread Zubair Quraishi
Hi Anton,

 In the Coils framework it does actually share structures (atoms) from the 
client to the server, which can then be replayed back to the client again. An 
example is at:

http://connecttous.co/

:where you can play around with the sample application, and then you can go to:

http://connecttous.co/connecttous/connecttous.html?playback=true

: to play back the sessions. The way this is done is by just sending the 
updates of the Om Application State to the server (assuming you are using David 
Nolen's Om for the client side) using Om's tx-listen. Here is where the code is:

https://github.com/zubairq/coils/search?q=tx-listen&ref=cmdform

: tx-listen takes two arguments, the first of which contains the changes:

 (fn [tx-data root-cursor]

: so you can do  (:path tx-data) to get just the changes to the GUI, which is 
what Coils does, and then it sends those changes to the server. To see the 
changes being sent live to the server, if you go to connecttous.co and do stuff 
in the GUI, then open the network console, you can see calls to the server 
which send the GUI state from client to server, by looking out for the calls 
which are something like this:

http://connecttous.co/connecttous/action?systemaction=!add-history¶ms=

:This sends the GUI changes back to the server, which then get stored in the 
backend.


Regarding Andrew Chamber's point about tree diff, Andrew is spot on! In fact 
when you do local debugging in Coils:

http://connecttous.co/connecttous/connecttous.html?livedebug=true

: on the right you can see changes to two trees that Coils uses, called UI and 
DATA. To show these changes it uses the Clojure diff call:

https://github.com/zubairq/coils/search?q=deleted+%28first+&type=Code

:which shows added and deleted entries from the trees. I hope this helps and 
that you can apply something similar to your own project.

Thanks
Zubair


-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


Re: [ClojureScript] Update Om demo with time travelling debugger

2014-07-23 Thread Zubair Quraishi
Quite a few people contacted me about the Time Travelling debugger, and I have 
taken the feedback and updated the live demo with a new version, incorporating 
the feedback. Let me know what you think:

http://connecttous.co/connecttous/connecttous.html?livedebug=true

On Wednesday, July 16, 2014 9:02:43 AM UTC+2, Zubair Quraishi wrote:
> On Wednesday, July 16, 2014 1:50:06 AM UTC+2, Ahmad Hammad wrote:
> > This is pretty cool Zubair. Good job.
> > 
> > I think the client-side debugger would be useful as a standalone library 
> > for those who don't want the full framework. How hard would it be to 
> > package that separately? I'd be happy to help do that.
> > 
> > Keep it up.
> > 
> > Ahmad Hammad
> 
> Sorry, I meant Ahmad, not Admad. I was typing too fast  and just pressed 
> send. I should have checked my reply first.

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


Re: [ClojureScript] Update Om demo with time travelling debugger

2014-07-16 Thread Zubair Quraishi
On Wednesday, July 16, 2014 1:50:06 AM UTC+2, Ahmad Hammad wrote:
> This is pretty cool Zubair. Good job.
> 
> I think the client-side debugger would be useful as a standalone library for 
> those who don't want the full framework. How hard would it be to package that 
> separately? I'd be happy to help do that.
> 
> Keep it up.
> 
> Ahmad Hammad

Sorry, I meant Ahmad, not Admad. I was typing too fast  and just pressed send. 
I should have checked my reply first.

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


Re: [ClojureScript] Update Om demo with time travelling debugger

2014-07-15 Thread Zubair Quraishi
On Wednesday, July 16, 2014 1:50:06 AM UTC+2, Ahmad Hammad wrote:
> This is pretty cool Zubair. Good job.
> 
> I think the client-side debugger would be useful as a standalone library for 
> those who don't want the full framework. How hard would it be to package that 
> separately? I'd be happy to help do that.
> 
> Keep it up.
> 
> Ahmad Hammad

Hi Admad,
 Glad you like it. Yes, the client-side library could be released as a 
standalone library, although there are many dependencies, for instance Om is a 
hard dependency so that the GUI state can be replayed. As far as all of the 
Code that is shown to be called that is done via macros, so you could not just 
add this to an existing ClojureScript application and then see the calls 
history. This is because the way that the code is shown is via the Clojure 
macros, so that if the code is compiled in debug mode then the code is saved to 
a list, and then a shadow call is made to the real function. I probably am 
explaining it in a really terrible, way, so I will have to write something more 
details online about how this works, as I am still working on the 
documentation. But something like this for the request form:

;
(defn-ui-component   request-form   [ui-data]
{:absolute-path [:ui :request]}
;

  (div
   nil
   (div
nil
(om/build from-email-field   (-> ui-data :from-email ))

(om/build  to-email-field  (-> ui-data :to-email ))


(dom/button #js {:onClick (fn [e]
(om/update! ui-data [:submit :value]  true))
 :style
 #js {:margin-top "10px"}}
"Connect")

(if (not (blank?
  (get-in ui-data [:submit :message])))
  (div nil "Submitted")


: call this macro:

(defmacro defn-ui-component [fn-name data-paramater-name opts & code ]

`(do

   (webapp.framework.client.coreclient/record-defn-ui-component
 (~'ns-coils-debug)
 ~(str `~fn-name) ~(str `~data-paramater-name)

  (str ~(with-out-str   (write (first `~code))
:dispatch clojure.pprint/code-dispatch))
)

   (defn ~fn-name [~(first data-paramater-name)  ~'owner]
 (~'reify

  ~'om/IInitState
  (~'init-state ~'[_]
  {:debug-highlight false})


   ~'om/IRender
   (~'render
[~'this]

 ~(if *show-code*
   `(webapp.framework.client.coreclient/debug-react
 ~(str `~fn-name)
 ~'owner
 ~(first data-paramater-name)
 (~'fn [~(first data-paramater-name)]
 ~@code))
(first code))
 )))


   (~'webapp.framework.client.coreclient/process-ui-component  ~opts)

   ))

: which calls these functions:


(defn record-defn-ui-component [namespace-name fname args & code]
  (let [
code-str
(str (apply str (map #(if (= "\n" %1) (str "\r\n")  %1) code)))
]

;(.log js/console (str "NAMESPACE: "namespace-name))
;(.log js/console (str "NAMESPACE fname: "  fname))
;(.log js/console (str "NAMESPACE orig code: "  code))
;(.log js/console (str "NAMESPACE code: "   code-str))

(reset!
 webapp.framework.client.system-globals/debugger-ui
 (assoc-in
  (deref webapp.framework.client.system-globals/debugger-ui)
  [:react-components-code (str fname)]
  (xml-str (str
"(ns  " namespace-name ")"
(char 13) (char 13)


"(defn-ui-component  "
 fname "  "
 args (char 13) (char 13)
 code-str
 ""
 )))
 )
)
  )



:and:

(defn debug-react [str-nm owner data react-fn]
  (let
[
 react-fn-name(str str-nm)
 ]
(do
  ;(log (str "render: " react-fn-name))
  ;(log (str "   : " (pr-str data)))
  (add-debug-event :event-type  "render"
   :component-name  react-fn-name
   :component-data  data
   )
  (dom/div
   #js {
:onMouseEnter #(if js/debug_live (om/set-state! owner 
:debug-highlight true))
:onMouseLeave #(if js/debug_live (om/set-state! owner 
:debug-highlight false))
:onClick component-clicked
:style (if js/debug_live
 #js {:backgroundColor

  (if
(om/get-state owner :debug-highlight)
(do
  (if (not= (:mode @debugger-ui) "component")
(set-debug-component  react-fn-name))
  "lightGray")
(do
  

Re: [ClojureScript] Update Om demo with time travelling debugger

2014-07-14 Thread Zubair Quraishi
Hi Johann,
 I have updated the introduction on Github. Here is basically what I said:

Why Neo4j?
--
One of the features of Coils is that allows all sessions to be replayed by the 
company developing a website using Coils, see here for a demo:

http://connecttous.co/connecttous/connecttous.html?playback=true

: So Coils is forced to choose something as the default. While Coils does 
natively support relational databases, and also can support other backends such 
as MongoDb through Clojure, Neo4j was chosen for the following reasons:

- Easy to setup Neo4j on a developer machine, withut having to create a schema 
first like with a database
- Rich data model, using Neo4j labels, as opposed to document databases like 
MongoDB
- Expressive and powerful Cypher query language
- Zubair has requested support in the past for bugs and the Neo4j team were 
super responsive
- Neo4j has funding and a large customer base, so they should be around a long 
time
- Neo4j has a dual licensing model, similar to Coils
- Neo4j is based close by in Malmo, not far from Copenhagen, so the core team 
are near by
- Some of the Neo4j guys are very active in the Clojure community
- Peter Neubauer, one of the foundof Neo4j is awesome and has always been 
helpful when there have been problems. Even though he is not at Neo4j anymore 
(now he is at Mapillary) he has always provided first class support

One of the other questions has been around whether Neo4j can have a realtime 
interface to Neo4j, like Meteor does with Mini Mongo and MongoDb. MongoDb uses 
a very simple document model which is why this works so well with MondoDb, but 
Coils goes one step further and has full client side access to Cypher queries, 
so it doesn't need a MiniNeo4j on the client side. So the answer is yes, Coils 
can have real time client side access to Neo4j.


On Tuesday, July 15, 2014 12:22:29 AM UTC+2, Johann Bestowrous wrote:
> Hey Zubair--read through your introduction to Coils. I was wondering what are 
> your reasons for choosing neo4j as a datastore? I know little about it and am 
> curious to hear what into the decision.
> 
> 
> On Monday, July 14, 2014 11:51:17 AM UTC-7, Zubair Quraishi wrote:
> > On Monday, July 14, 2014 8:46:03 PM UTC+2, Sean Grove wrote:
> > > Very nice! Very fast as well, fun to scroll through.
> > > 
> > > 
> > > 
> > > On Mon, Jul 14, 2014 at 11:44 AM, Zubair Quraishi  
> > > wrote:
> > > 
> > > 
> > > http://connecttous.co/connecttous/connecttous.html?livedebug=true
> > > 
> > > 
> > > 
> > > 
> > > 
> > > Play around with the app and then press Debug at the top. Then either 
> > > drag the slide to view the events and code, or click on a gui component 
> > > to see the Om component code
> > > 
> > > 
> > > 
> > > --
> > > 
> > > Note that posts from new members are moderated - please be patient with 
> > > your first post.
> > > 
> > > ---
> > > 
> > > You received this message because you are subscribed to the Google Groups 
> > > "ClojureScript" group.
> > > 
> > > To unsubscribe from this group and stop receiving emails from it, send an 
> > > email to clojurescrip...@googlegroups.com.
> > > 
> > > To post to this group, send email to clojur...@googlegroups.com.
> > > 
> > > Visit this group at http://groups.google.com/group/clojurescript.
> > 
> > Thanks, I am still working on the documentation (the examples out of date) 
> > but it is up on github here:
> > 
> > https://github.com/zubairq/coils

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


Re: [ClojureScript] Update Om demo with time travelling debugger

2014-07-14 Thread Zubair Quraishi
On Monday, July 14, 2014 8:46:03 PM UTC+2, Sean Grove wrote:
> Very nice! Very fast as well, fun to scroll through.
> 
> 
> 
> On Mon, Jul 14, 2014 at 11:44 AM, Zubair Quraishi  wrote:
> 
> 
> http://connecttous.co/connecttous/connecttous.html?livedebug=true
> 
> 
> 
> 
> 
> Play around with the app and then press Debug at the top. Then either drag 
> the slide to view the events and code, or click on a gui component to see the 
> Om component code
> 
> 
> 
> --
> 
> Note that posts from new members are moderated - please be patient with your 
> first post.
> 
> ---
> 
> You received this message because you are subscribed to the Google Groups 
> "ClojureScript" group.
> 
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to clojurescrip...@googlegroups.com.
> 
> To post to this group, send email to clojur...@googlegroups.com.
> 
> Visit this group at http://groups.google.com/group/clojurescript.

Thanks, I am still working on the documentation (the examples out of date) but 
it is up on github here:

https://github.com/zubairq/coils

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Update Om demo with time travelling debugger

2014-07-14 Thread Zubair Quraishi
http://connecttous.co/connecttous/connecttous.html?livedebug=true

Play around with the app and then press Debug at the top. Then either drag the 
slide to view the events and code, or click on a gui component to see the Om 
component code

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Coils - Another demo on Clojurescript Om web app playback

2014-07-06 Thread Zubair Quraishi
I posted a playback example earlier using the Coils framework which uses 
David's Nolen's Om framework. Now you can also step through time, and see the 
source too:

http://connecttous.co/connecttous/connecttous.html?livedebug=true

:Play with the app then press the "debug" button at the top

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


[ClojureScript] Simple example of session playback with Om Clojurescript

2014-05-12 Thread Zubair Quraishi
Code: https://github.com/zubairq/coils/tree/connecttous
Demo: connecttous.co (click See "previous sessions" at the bottom) 

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.


Re: [ClojureScript] Om: Question about how best to structure app state and use cursors

2014-04-10 Thread Zubair Quraishi
regarding the comment I made about Hoplon, it seems that if you want to listen 
to different parts of the tree then in effect you are saying that when one part 
of the tree changes that you would like to project that part of the tree onto 
another part of the tree, which is something hoplon does. Maybe an atom to 
watch the Om tree could do the same

On Thursday, April 10, 2014 11:02:26 AM UTC+2, Dimitris Stefanidis wrote:
> I was thinking about the same too and was trying to find a way to apply this 
> in om since this problem appears too often. 
> 
> 
> 
> It would be nice if I could have a products vector in my state and a selected 
> products vector. The products list component would get both products and 
> selected products cursors and would add any selected items in the selected 
> products cursor. Other components could get the selected products cursor and 
> display summaries detailed lists e.t.c. 
> 
> 
> 
> This way components do not have to know anything about the structure of the 
> application state. Of course there might be other caveats in this approach 
> that are probably missing me.
> 
> 
> 
> On Thursday, April 10, 2014 11:49:03 AM UTC+3, Jack Schaedler wrote:
> 
> > Does it make any sense to allow components to reference multiple cursors? 
> > Instead of specifying a single path into the application state, you would 
> > specify a collection of paths within the state atom, all of which would 
> > trigger re-renders and allow for transact! and update!? I often find myself 
> > pulling component cursor paths 'up' the tree in order to ensure that the 
> > cursor is broad enough to capture all of the state changes that might cause 
> > a re-render.
> 
> > 
> 
> > 
> 
> > 
> 
> > That being said, I still have the feeling that in the majority of cases, 
> > the confined scope of the cursor guides me towards a more sensible layout 
> > of the application state.
> 
> > 
> 
> > 
> 
> > 
> 
> > 
> 
> > 
> 
> > On Thursday, April 10, 2014 4:12:31 AM UTC+2, David Nolen wrote:
> 
> > 
> 
> > > Yes it's a problem that you encounter in React if you try to do things in 
> > > a functional manner. It's not really a "limitation" of React or Om. But 
> > > at least in the case of Om I consider it a deficiency great enough to 
> > > build direct support so that users aren't hampered by it or forced to 
> > > come up with their own ad-hoc solutions.
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > David
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > On Wed, Apr 9, 2014 at 10:05 PM, Brendan Stromberger 
> > >  wrote:
> 
> > 
> 
> > > 
> 
> > 
> 
> > > I've encountered this issue in vanilla React (js), and couldn't figure 
> > > out any other way than munging my data together such that I could pass it 
> > > down in the way OP describes. I guess my question is, is this limitation 
> > > inherent in React or in the Om abstraction?
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > On Wednesday, April 9, 2014 3:52:05 AM UTC-7, David Nolen wrote:
> 
> > 
> 
> > > 
> 
> > 
> 
> > > > You're not missing anything. This is a fundamental issue in Om right 
> > > > now and I've been designing and working on a fix. Basically in the very 
> > > > near future a component will be able to access something in the 
> > > > application state without needing a parent component to pass it in from 
> > > > above.
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > > The idea is that a component will be able to get its data directly from 
> > > > the app state with something like (om/get-shared owner [:app-state 
> > > > :foo]).
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > > Still working out the details, but this work is happening in the 
> > > > `ind-components` branch. When it's finished there'll be an accompanying 
> > > > nested tab view example - one of the cases that suffers the most under 
> > > > the current system.
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > > David
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > > On Wed, Apr 9, 2014 at 6:33 AM, Daniel Kersten  
> > > > wrote:
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > > Hi,
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > > I'm trying to figure out the best way of structuring complex 
> > > > applications in Om and I've hit a bit of a brick wall that I'm hoping 
> > > > someone can help me with.
> 
> > 

Re: [ClojureScript] Om: Question about how best to structure app state and use cursors

2014-04-10 Thread Zubair Quraishi
Sounds like you may want a reactive programming model like Hoplon instead if 
you want to do this:

http://hoplon.io/


On Thursday, April 10, 2014 11:02:26 AM UTC+2, Dimitris Stefanidis wrote:
> I was thinking about the same too and was trying to find a way to apply this 
> in om since this problem appears too often. 
> 
> 
> 
> It would be nice if I could have a products vector in my state and a selected 
> products vector. The products list component would get both products and 
> selected products cursors and would add any selected items in the selected 
> products cursor. Other components could get the selected products cursor and 
> display summaries detailed lists e.t.c. 
> 
> 
> 
> This way components do not have to know anything about the structure of the 
> application state. Of course there might be other caveats in this approach 
> that are probably missing me.
> 
> 
> 
> On Thursday, April 10, 2014 11:49:03 AM UTC+3, Jack Schaedler wrote:
> 
> > Does it make any sense to allow components to reference multiple cursors? 
> > Instead of specifying a single path into the application state, you would 
> > specify a collection of paths within the state atom, all of which would 
> > trigger re-renders and allow for transact! and update!? I often find myself 
> > pulling component cursor paths 'up' the tree in order to ensure that the 
> > cursor is broad enough to capture all of the state changes that might cause 
> > a re-render.
> 
> > 
> 
> > 
> 
> > 
> 
> > That being said, I still have the feeling that in the majority of cases, 
> > the confined scope of the cursor guides me towards a more sensible layout 
> > of the application state.
> 
> > 
> 
> > 
> 
> > 
> 
> > 
> 
> > 
> 
> > On Thursday, April 10, 2014 4:12:31 AM UTC+2, David Nolen wrote:
> 
> > 
> 
> > > Yes it's a problem that you encounter in React if you try to do things in 
> > > a functional manner. It's not really a "limitation" of React or Om. But 
> > > at least in the case of Om I consider it a deficiency great enough to 
> > > build direct support so that users aren't hampered by it or forced to 
> > > come up with their own ad-hoc solutions.
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > David
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > On Wed, Apr 9, 2014 at 10:05 PM, Brendan Stromberger 
> > >  wrote:
> 
> > 
> 
> > > 
> 
> > 
> 
> > > I've encountered this issue in vanilla React (js), and couldn't figure 
> > > out any other way than munging my data together such that I could pass it 
> > > down in the way OP describes. I guess my question is, is this limitation 
> > > inherent in React or in the Om abstraction?
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > On Wednesday, April 9, 2014 3:52:05 AM UTC-7, David Nolen wrote:
> 
> > 
> 
> > > 
> 
> > 
> 
> > > > You're not missing anything. This is a fundamental issue in Om right 
> > > > now and I've been designing and working on a fix. Basically in the very 
> > > > near future a component will be able to access something in the 
> > > > application state without needing a parent component to pass it in from 
> > > > above.
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > > The idea is that a component will be able to get its data directly from 
> > > > the app state with something like (om/get-shared owner [:app-state 
> > > > :foo]).
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > > Still working out the details, but this work is happening in the 
> > > > `ind-components` branch. When it's finished there'll be an accompanying 
> > > > nested tab view example - one of the cases that suffers the most under 
> > > > the current system.
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > > David
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > 
> 
> > 
> 
> > > > On Wed, Apr 9, 2014 at 6:33 AM, Daniel Kersten  
> > > > wrote:
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > > Hi,
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > > I'm trying to figure out the best way of structuring complex 
> > > > applications in Om and I've hit a bit of a brick wall that I'm hoping 
> > > > someone can help me with.
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > >
> 
> > 
> 
> > > 
> 
> > 
> 
> > > > I like the concept