From the course: Create a CRM Mobile Application with React Native
Unlock the full course today
Join today to access over 24,800 courses taught by industry experts.
Update person view - React Native Tutorial
From the course: Create a CRM Mobile Application with React Native
Update person view
- [Narrator] Okay, so now we're going to work on the UpdatePerson view and the component. And the cool thing about this particular component is that we've written a lot of the code already on the AddPerson. So what we're going to do is primarily copy all of the code from the AddPerson view, all of it like so, and then put it in the UpdatePerson and then change what we need to change. Basically select all. So I did Command A on Mac and Ctrl A on Windows, and then I'm going to paste it like so. And then I'm going to make all the changes that I need to make. So the first thing that I need to change is in here, the actual name of the class itself. We're going to call this UpdatePerson and make sure that at the end, we change it accordingly here. Perfect. Now the second thing that we need to change is this one here. The function is not on AddPress, but on UpdatePress. And we're going to change it to where the button is too. And if you want to make sure that you're writing the right thing…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.