Skip to content

Commit 0bcb848

Browse files
author
Rafael Dias
committed
adjust readme file
1 parent 6a656c3 commit 0bcb848

File tree

4 files changed

+16
-95
lines changed

4 files changed

+16
-95
lines changed

README.md

Lines changed: 14 additions & 87 deletions
Original file line numberDiff line numberDiff line change
@@ -1,96 +1,23 @@
1-
# React Native Template App
1+
# React Native Uber Clone App
22

3-
Template projeto React-native [React Native](https://facebook.github.io/react-native/)
3+
The main idea of this project is to show how can React Native interact with Google Maps API and Geolocation API.
44

5-
Arquitetura escolhida para separar UI de lógica de negócio.
5+
## React with Hooks
66

7-
## Arquitetura
7+
- react 16.8.6
8+
- react-native 0.60.3
89

9-
- **Presentational Components & Containers(Screens)**
10+
---
1011

11-
Presentational components => parte react, componentes menores;
12-
Containers => parte redux/saga (containers contém presentational components e conectam tudo ao redux/saga;
13-
14-
[Post](https://medium.com/@dan_abramov/smart-and-dumb-components-7ca2f9a7c7d0) do Dan Abramov sobre o assunto.
12+
## Third party libraries used to support this implementation
1513

16-
- **State/Store com Redux [Redux](https://redux.js.org/)**.
14+
- [react-native-geocoding](https://github.com/marlove/react-native-geocoding)
15+
- [react-native-maps](https://github.com/react-native-community/react-native-maps)
16+
- [react-native-maps-directions](https://github.com/bramus/react-native-maps-directions)
17+
- [react-native-google-places-autocomplete](https://github.com/FaridSafi/react-native-google-places-autocomplete)
1718

18-
Redux facilita o compartilhamento de estado entre todos os componentes da aplicação, evitando passar props entre diversos componentes.
19+
---
1920

20-
Com Redux, o estado é compartilhado utilizando *stores* globais, e alterações de estado são previsíveis: *actions* são aplicadas por *reducers* ao estado/store.
21-
22-
- **Chamadas Asyncronas são gerenciadas com [Redux Saga](https://redux-saga.js.org/)**.
21+
## License
2322

24-
Sagas são disparadas por Redux Actions e também podem alterar a Store redux, utilizando Javascript generator (`yield`).
25-
26-
27-
## Links auxiliares
28-
29-
- [Pastas](#Pastas) estrutura de pastas do projeto
30-
- [Redux](https://redux.js.org/) gerenciar estado global da aplicação
31-
- [Redux Persist](https://github.com/rt2zz/redux-persist) Persiste store na AsyncStorage
32-
- [Redux Sagas](https://redux-saga.js.org) controlar fluxos asyncronos
33-
- [React Navigation](https://reactnavigation.org/)
34-
[`NavigationService`](App/Services/NavigationService.js) Usa navegaçao como um servico para tratar as rotas e adicionar splash screen
35-
- [prettier](https://prettier.io/) & [eslint](https://eslint.org/) configurados pra react-native
36-
37-
### OPCIONAL - Bibliotecas auxiliáres para facilitar a integracao com redux e axios - não obrigatórias
38-
- [reduxsauce](https://github.com/infinitered/reduxsauce) (v0.7) to facilitate using Redux
39-
- [apisauce](https://github.com/infinitered/apisauce) facilita usar o axios [axios](https://github.com/axios/axios)
40-
41-
42-
## Pastas
43-
44-
- [`App/Components`](App/Components): presentational components (telas)
45-
- [`App/Config`](App/Config): configuracao global do app (variáveis, funções)
46-
- [`App/Containers`](App/Containers): container components/ Screens - contém lógica redux
47-
- [`App/Images`](App/Images): imagens da aplicacao
48-
- [`App/Services`](App/Services): API
49-
- [`App/Redux/Sagas`](App/Redux/Sagas): redux sagas
50-
- [`App/Redux/Stores`](App/Redux/Stores): Config para criar store, aplicar middlewares, sagas, etc
51-
- [`App/Redux/Actions`](App/Redux/Actions): actions e actions creators
52-
- [`App/Redux/Reducers`](App/Redux/Reducers): reducers
53-
- [`App/Redux/Helpers`](App/Redux/Helpers): helpers - auxiliam em funcoes get na store, padronizando chamadas
54-
- [`App/Theme`](App/Theme): thema para o app
55-
56-
## Requisitos
57-
58-
- Node 8.+
59-
- Xcode 9.+
60-
61-
Também instalar as dependências requeridas para React Native.
62-
63-
- [Android development](https://facebook.github.io/react-native/docs/getting-started.html#installing-dependencies-3)
64-
- [iOS development](https://facebook.github.io/react-native/docs/getting-started.html#installing-dependencies)
65-
66-
## Utilizando o projeto
67-
68-
- clonar o repositório
69-
- remova qualquer histórico do git: `rm -rf .git/`
70-
- crie um novo projeto git: `git init`
71-
- npm install
72-
- renomear o projeto utilizando [reacnt-native-rename](https://www.npmjs.com/package/react-native-rename), conforme abaixo:
73-
```
74-
$ npm install react-native-rename -g
75-
$ git checkout -b rename-app
76-
$ react-native-rename <novoNome> -b <com.agileteam.novoNome>
77-
78-
// Remove pastas android e ios antigas
79-
$ rm -rf android/ ios/
80-
81-
// Regerar pastas android e ios com novo nome do app
82-
$ react-native upgrade
83-
84-
$ react-native link
85-
```
86-
87-
88-
89-
## Rodando o projeto
90-
91-
- `react-native run-android` (lembre-se de já ter o emulador ou um telefone android conectado)
92-
- `react-native run-ios` (lembre-see de já ter o simulator ou um telefone iPhone conectado)
93-
94-
### Build para distribuição Betas
95-
96-
[Beta builds](docs/beta%20builds.md)
23+
This project is licensed under the MIT License.

package-lock.json

Lines changed: 0 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@
3232
"redux-persist": "^5.10.0",
3333
"redux-persist-transform-immutable": "^5.0.0",
3434
"redux-saga": "^1.0.5",
35-
"redux-saga-location": "^1.3.0",
3635
"styled-components": "^4.3.2"
3736
},
3837
"devDependencies": {

src/components/Map/index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ const Map = ({
6161
/>
6262
<Marker coordinate={region} anchor={{ x: 0, y: 0 }}>
6363
<LocationBox>
64-
<LocationText>{destination.title}</LocationText>
64+
<LocationText>{location}</LocationText>
6565
</LocationBox>
6666
</Marker>
6767

@@ -75,7 +75,7 @@ const Map = ({
7575
<LocationTimeText>{timeToDestination}</LocationTimeText>
7676
<LocationTimeTextSmall>min</LocationTimeTextSmall>
7777
</LocationTimeBox>
78-
<LocationText>{location}</LocationText>
78+
<LocationText>{destination.title}</LocationText>
7979
</LocationBox>
8080
</Marker>
8181
</Fragment>

0 commit comments

Comments
 (0)