1琢岩、Warning: Can't perform a React state update on an unmounted component. This is a no-op, but it indicates a memory leak in your application. To fix, cancel all subscriptions and asynchronous tasks in the componentWillUnmount method.
出現(xiàn)這個問題有可能是因為在組件里使用了定時器,但在組件卸載時沒有銷毀迷帜。定時器執(zhí)行的時候發(fā)現(xiàn)組件已經(jīng)卸載從而報錯。
解決方式:銷毀定時器
2色洞、鍵盤遮住輸入框
解決方式: 用keyboardavoidingview組件包裹住View戏锹,Modal里也是一樣的。
3火诸、點擊空白處無法隱藏鍵盤
解決方式: 用ScrollView包裹住對應(yīng)的內(nèi)容锦针,點擊空白處會隱藏鍵盤
4、ios發(fā)送郵件時無法打開自帶的Mail郵箱
注意,ios發(fā)送郵件時的url一定是下面這種結(jié)構(gòu)伞插,其中cc=&不能少割粮,不然打開Mail會失敗
let url = `mailto:${to}?cc=&subject=${subject}&body=${body}`;