Permalink
Browse files

simplify the example

  • Loading branch information...
swannodette committed Jun 14, 2017
1 parent f5bea03 commit a1a556e100f45ec47f00d1d33069a08cb0fe761b
Showing with 7 additions and 7 deletions.
  1. +7 −7 README.md
@@ -38,18 +38,18 @@ dependency information:

```clojure
(ns example
(:require [om.dom :as dom]
[om.next :as om]))
(:require [goog.dom :as gdom]
[om.dom :as dom]
[om.next :as om :refer [defui]]))
(defui Widget
(defui Hello
Object
(render [this]
(dom/h1 nil (:text (om/props this)))))
(dom/h1 nil "Hello, world!")))
(def widget (om/factory Widget))
(def hello (om/factory Hello))
(om/add-root! widget {:text "Hello world!"}
{:target (. js/document (getElementById "my-app"))})
(.render js/ReactDOM (hello) (gdom/getElement "example"))
```
## Tutorials

0 comments on commit a1a556e

Please sign in to comment.