I'm running a basic `lein new om-weasel ...` project with this core.cljs file:

(ns omw.core
  (:require [om.core :as om :include-macros true]
            [om.dom :as dom :include-macros true]))

(enable-console-print!)

(def app-state (atom {:text "Hello world!"}))

(when-let [dom-el (.getElementById js/document "app")]
  (om/root (fn [app owner]
             (dom/h1 nil (:text app)))
           app-state
           {:target dom-el}))


..... but I keep receiving this error when I try to evaluate any of it in Emacs Cider 0.7:


"Error evaluating:" (when-let [dom-el (.getElementById js/document "app")] (om/root (fn [app owner] (dom/h1 nil (:text app))) app-state {:target dom-el})) :as "var temp__4222__auto___14357 = document.getElementById(\"app\");if(cljs.core.truth_(temp__4222__auto___14357))\n{var dom_el_14358 = temp__4222__auto___14357;om.core.root.call(null,((function (dom_el_14358,temp__4222__auto___14357){\nreturn (function (app,owner){return React.DOM.h1(null,new cljs.core.Keyword(null,\"text\",\"text\",-1790561697).cljs$core$IFn$_invoke$arity$1(app));\n});})(dom_el_14358,temp__4222__auto___14357))\n,omw.core.app_state,new cljs.core.PersistentArrayMap(null, 1, [new cljs.core.Keyword(null,\"target\",\"target\",253001721),dom_el_14358], null));\n} else\n{}\n" #<Error: Assert failed: Invalid Om component fn, does not return valid instance
(or (satisfies? IRender x) (satisfies? IRenderState x))>
Error: Assert failed: Invalid Om component fn, does not return valid instance
(or (satisfies? IRender x) (satisfies? IRenderState x))


gvim

--
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