As long as you're willing to do all the work required for custom types - no
I don't forsee any real problems.

David

On Thu, Apr 23, 2015 at 2:04 PM, <[email protected]> wrote:

> Up till now, I've only ever put plain maps and vectors into the Om state
> atom. I'm now working on a few things where it would be *really* nice to
> have polymorphic dispatch on stuff that has come from the app state (once
> it's been deref-ed, via a cursor).
>
> I've done a few tests, replacing some maps with defrecord instances, and
> dispatching the downstream logic via protocols, and this seems to work just
> fine.
>
> But it's not something I've seen done in any of the examples. And I'm sure
> I've seen guidance to avoid putting *certain* types (from memory, native
> base types) into the atom, which makes me (perhaps overly) cautious.
>
> So before I get too far into this, figured it was worth checking if there
> are any theoretical problems here? Is there anything in the underlying Om
> or cursor assumptions that is likely to break or get complicated if I start
> putting lots of defrecord (or possibly, later, deftype or reify) instances
> in there?
>
> Advice appreciated.
>
> J.
>
> --
> 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