This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-03-28
Channels
- # aleph (48)
- # announcements (3)
- # bangalore-clj (1)
- # beginners (131)
- # cider (30)
- # cljdoc (6)
- # cljs-dev (53)
- # cljsrn (24)
- # clojure (312)
- # clojure-austin (2)
- # clojure-europe (4)
- # clojure-finland (6)
- # clojure-nl (24)
- # clojure-spec (24)
- # clojure-uk (66)
- # clojurescript (185)
- # core-async (46)
- # cursive (10)
- # data-science (9)
- # datomic (15)
- # devcards (2)
- # emacs (50)
- # fulcro (28)
- # jobs (1)
- # jobs-discuss (2)
- # kaocha (11)
- # lein-figwheel (12)
- # nyc (1)
- # off-topic (105)
- # other-languages (80)
- # pedestal (6)
- # re-frame (50)
- # reagent (5)
- # reitit (1)
- # remote-jobs (2)
- # ring (10)
- # rum (1)
- # shadow-cljs (10)
- # spacemacs (19)
@souenzzo For re-frame it seems to work well. But if not then maybe add local state to the component?
If you have your business code perfectly isolated then you can just run the tests in node as ususal. But if you require in RN like we do you might have to mock out things.
I know @plexus has been doing very good things on testing with his kaocha lib. So he is probably better to help you out, maybe in the #kaocha channel. Our testing setup is 3 years old and a bit of a frankestein, so while it works for us I can’t really recommend others to try it 😛
If you are using shadow-cljs, @manu, then you configure the test runner like so: https://shadow-cljs.github.io/docs/UsersGuide.html#target-node-test
@souenzzo If you’re seeing lag on a TextInput
, don’t set the :value
to an atom. If you need an initial value, use :default-value @some-atom
The atom bit is just because people generally use a reagent atom to store state for their text-inputs. You can put a straight string in there for a default value if you want as well.
I wrote a quick blog post on that quick keyboard lag issue, since it seems to come up a lot: https://increasinglyfunctional.com/2019/03/28/why-clojurescript-react-native-text-input-slow.html