This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2016-03-23
Channels
- # admin-announcements (6)
- # aleph (3)
- # beginners (38)
- # boot (119)
- # braid-chat (15)
- # braveandtrue (1)
- # clara (4)
- # cljs-dev (56)
- # cljsfiddle (12)
- # cljsjs (15)
- # cljsrn (6)
- # clojars (4)
- # clojure (113)
- # clojure-art (1)
- # clojure-berlin (1)
- # clojure-dusseldorf (3)
- # clojure-india (15)
- # clojure-new-zealand (3)
- # clojure-poland (1)
- # clojure-russia (83)
- # clojure-uk (18)
- # clojurescript (97)
- # community-development (9)
- # cursive (1)
- # data-science (1)
- # datomic (12)
- # emacs (14)
- # hoplon (350)
- # immutant (2)
- # jobs (2)
- # jobs-discuss (23)
- # keechma (74)
- # liberator (1)
- # off-topic (1)
- # om (127)
- # onyx (54)
- # parinfer (74)
- # pedestal (1)
- # proton (5)
- # re-frame (6)
- # reagent (4)
- # remote-jobs (17)
- # ring-swagger (1)
- # slack-help (5)
- # untangled (16)
- # yada (21)
What’s the best way to move a view up/down with the showing/hiding of a keyboard, in a reagent/re-frame project? (Imagine a simple chat UI where the keyboard ends up covering the input-text view when it’s shown.) I’ve seen a couple js examples where they listen to lifecycle events and attach keyboardWillShow
and keyboardWillHide
events, and set a state to update the view size accordingly. Is there a more straightforward way to do so without mucking with lifecycle methods?
Looking through the re-frame wiki (https://github.com/Day8/re-frame/wiki/Creating-Reagent-Components#form-3-a-class-with-life-cycle-methods), it mentions that you’d probably use Form-3 less than 1% of the time… Is this situation part of the 1%?
@jessica: there's a nice drop in js package for keyboard spacing. Let me check on my laptop...
But if you want to have more control over it you would have to use the lifecycle methods yes
@jessica: sorry, forgot to actually send it from my laptop. try this: https://github.com/Andr3wHur5t/react-native-keyboard-spacer