- Hands-On Design Patterns with React Native
- Mateusz Grzesiukiewicz
- 156字
- 2021-08-13 15:13:01
Building forms
In this section, we will explore how we can handle text input from users. Traditional means of collecting input from so-called forms is divided into two major ways: controlled and uncontrolled. In a native environment, this means either handling any keypress on the React Native side (controlled input), or letting it be handled on the native system level and collecting data in React on demand (uncontrolled input).
If you come from a web development background, please note that, at the time of writing this book, there is no form component, and I don't see it coming. There are also limitations to refs and what you can do with them. For instance, you cannot ask a ref to a TextInput for its current value. Please follow the following two subsections for more details. You can also use custom libraries, but I will not discuss such solutions here as these tend to change often.
推薦閱讀
- Go Web編程
- Python Game Programming By Example
- 看透JavaScript:原理、方法與實踐
- 程序員考試案例梳理、真題透解與強化訓(xùn)練
- Building Mobile Applications Using Kendo UI Mobile and ASP.NET Web API
- Python Web數(shù)據(jù)分析可視化:基于Django框架的開發(fā)實戰(zhàn)
- Python Data Analysis Cookbook
- Java程序設(shè)計入門
- 一塊面包板玩轉(zhuǎn)Arduino編程
- Visualforce Developer’s guide
- 基于SpringBoot實現(xiàn):Java分布式中間件開發(fā)入門與實戰(zhàn)
- UI設(shè)計基礎(chǔ)培訓(xùn)教程(全彩版)
- Kotlin程序員面試算法寶典
- Learning jqPlot
- Learning Ext JS(Fourth Edition)