Only associative types are supported as cursors out of the box. Seqs
are not associative, Vectors are.

David

On Mon, Sep 8, 2014 at 4:44 PM, stephanos <[email protected]> wrote:
> Hey there,
>
> I'm trying to understand this bit from the Om TodoMVC app:
>
>   (defn toggle-all [e state]
>     (let [checked (.. e -target -checked)]
>        (om/transact! state :todos
>          (fn [todos] (vec (map #(assoc % :completed checked) todos))))))
>
> What I don't understand is: why is the 'vec' function used here? It seems to 
> work fine without it.
>
> Regards
> Stephan
>
> --
> 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 [email protected].
> To post to this group, send email to [email protected].
> 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 [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/clojurescript.

Reply via email to