This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-06-05
Channels
- # aws (6)
- # beginners (10)
- # boot (33)
- # cider (23)
- # cljs-dev (50)
- # cljsjs (2)
- # cljsrn (10)
- # clojars (1)
- # clojure (215)
- # clojure-czech (1)
- # clojure-dev (5)
- # clojure-italy (23)
- # clojure-russia (18)
- # clojure-spec (11)
- # clojure-uk (53)
- # clojurescript (157)
- # core-async (29)
- # cursive (12)
- # data-science (15)
- # datascript (16)
- # datomic (68)
- # graphql (2)
- # jobs (5)
- # jobs-discuss (1)
- # juxt (17)
- # lein-figwheel (2)
- # luminus (3)
- # off-topic (155)
- # om (3)
- # pedestal (1)
- # portkey (1)
- # re-frame (7)
- # reagent (4)
- # ring (3)
- # ring-swagger (2)
- # rum (11)
- # unrepl (11)
- # vim (1)
- # yada (2)
hello everyone, Iām new to clojurescript with react native, is there some recommended tutorial?
@charafau Check out http://cljsrn.org/ for a bunch of resources
I'm (trying to) develop an app and I'm adding images. In my code:
(defn action-button [img action-fn]
(touchable-highlight {:onPress action-fn}
(image {:source (js/require img)
:style {:width 35 :height 35}})))
(def event-action (partial action-button "./images/events.png"))
(def beer-action (partial action-button "./images/drinks.png"))
(def question-action (partial action-button "./images/questions.png"))
(def chat-action (partial action-button "./images/chat.png"))
This works when I run the app in dev mode (`lein figwheel android`). However, when I build an apk (after lein prod-build
), the app crashes during startup. In logcat, I'm mainly worried about:
06-05 20:44:21.618 12670 12700 E ReactNativeJS: Requiring unknown module "./images/events.png".
06-05 20:44:21.629 12670 12700 E ReactNativeJS: Requiring unknown module "./images/drinks.png".
06-05 20:44:21.633 12670 12728 I cr_LibraryLoader: Time to load native libraries: 7 ms (timestamps 9363-9370)
06-05 20:44:21.637 12670 12700 E ReactNativeJS: Requiring unknown module "./images/questions.png".
06-05 20:44:21.644 12670 12700 E ReactNativeJS: Requiring unknown module "./images/chat.png".
Could this be the problem? Or could it be something else? (And d'you need a full logcat š?)or: how to add non-static images to a cljsrn app?
@kurt-o-sys I have had that problem as well. Unfortunately I haven't found the solution yet but a clean install seems to solve it. (Full clean, gradle + react + Lein)
carocad: it seems (logically) to be related to: https://github.com/facebook/react-native/issues/2481
(https://facebook.github.io/react-native/docs/images.html#images-from-hybrid-app-s-resources)
(image {src "..."})
seems to handle only static files. Having my code above does (probably?) not add a 'static' image.
Also, and that didn't change yet, the resources seem to be loaded 15 times(!).
hi guys i am looking for resources on how to develop apps with clj/cljs and i found cljsrn site i was wondering do i have to know react native to be able to develop apps? are there any prerequisites before i start? are these the most basic apps that i can use as a starting point? https://github.com/drapanjanas/re-natal#example-apps
@lepistane by this do you mean familiarity with developing React Native apps using just JavaScript?