Building the app
The UI of the app should look something like this:
It will have a search bar, a result list, and a map where we can visually locate the search results. We have already created the app and imported the data; now open it with the editor of your choice and start creating the required folders and files:
As you may have noticed, we are keeping the same folder structure as we did in the previous chapters. Since we will be using Redux to store some of the application's state, our first step is to define the user actions and what state we want to persist. Let's list them:
- A text query: We can persist the user input in our store
- Returned results: We will persist the result from the query and pass it down to the children components for rendering
- Going to a location: The user should be able to click on an item in the result list and the map should be updated to that location based on the latitude and longitude of the record
Let's start creating all the actions creators and action types in...