adopt reagent and reagent6 templates for RN 0.25

This commit is contained in:
Artur Girenko 2016-05-05 18:35:20 +02:00
parent 5cf02cc758
commit 2c1913038e
3 changed files with 16 additions and 15 deletions

View File

@ -29,7 +29,7 @@ devHostRx = /\$DEV_HOST\$/g
ipAddressRx = /^(?:[0-9]{1,3}\.){3}[0-9]{1,3}$/i
figwheelUrlRx = /ws:\/\/[0-9a-zA-Z\.]*:/g
serverRx = /http:\/\/[^:]+/g
rnVersion = '0.25.0'
rnVersion = '0.25.1'
rnPackagerPort = 8081
process.title = 're-natal'
interfaceConf =

View File

@ -4,18 +4,19 @@
[$PROJECT_NAME_HYPHENATED$.handlers]
[$PROJECT_NAME_HYPHENATED$.subs]))
(set! js/window.React (js/require "react-native"))
(set! js/window.React (js/require "react"))
(def ReactNative (js/require "react-native"))
(def app-registry (.-AppRegistry js/React))
(def text (r/adapt-react-class (.-Text js/React)))
(def view (r/adapt-react-class (.-View js/React)))
(def image (r/adapt-react-class (.-Image js/React)))
(def touchable-highlight (r/adapt-react-class (.-TouchableHighlight js/React)))
(def app-registry (.-AppRegistry ReactNative))
(def text (r/adapt-react-class (.-Text ReactNative)))
(def view (r/adapt-react-class (.-View ReactNative)))
(def image (r/adapt-react-class (.-Image ReactNative)))
(def touchable-highlight (r/adapt-react-class (.-TouchableHighlight ReactNative)))
(def logo-img (js/require "./images/cljs.png"))
(defn alert [title]
(.alert (.-Alert js/React) title))
(.alert (.-Alert ReactNative) title))
(defn app-root []
(let [greeting (subscribe [:get-greeting])]

View File

@ -4,18 +4,18 @@
[$PROJECT_NAME_HYPHENATED$.handlers]
[$PROJECT_NAME_HYPHENATED$.subs]))
(def react-native (js/require "react-native"))
(def ReactNative (js/require "react-native"))
(def app-registry (.-AppRegistry react-native))
(def text (r/adapt-react-class (.-Text react-native)))
(def view (r/adapt-react-class (.-View react-native)))
(def image (r/adapt-react-class (.-Image react-native)))
(def touchable-highlight (r/adapt-react-class (.-TouchableHighlight react-native)))
(def app-registry (.-AppRegistry ReactNative))
(def text (r/adapt-react-class (.-Text ReactNative)))
(def view (r/adapt-react-class (.-View ReactNative)))
(def image (r/adapt-react-class (.-Image ReactNative)))
(def touchable-highlight (r/adapt-react-class (.-TouchableHighlight ReactNative)))
(def logo-img (js/require "./images/cljs.png"))
(defn alert [title]
(.alert (.-Alert react-native) title))
(.alert (.-Alert ReactNative) title))
(defn app-root []
(let [greeting (subscribe [:get-greeting])]