Skip to content

Commit abaf8bb

Browse files
author
Matthieu Napoli
committed
Add code comments
1 parent ce6ccd8 commit abaf8bb

File tree

6 files changed

+18
-0
lines changed

6 files changed

+18
-0
lines changed

App/Containers/Example/ExampleScreen.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,13 @@ import ExampleActions from 'App/Stores/Example/Actions'
66
import { isHot } from 'App/Stores/Example/Selectors'
77
import Style from './ExampleScreenStyle'
88

9+
/**
10+
* This is an example of a container component.
11+
*
12+
* This screen displays a little help message and shows the weather temperature.
13+
* Feel free to remove it.
14+
*/
15+
916
const instructions = Platform.select({
1017
ios: 'Press Cmd+R to reload,\nCmd+D or shake for dev menu.',
1118
android: 'Double tap R on your keyboard to reload,\nShake or press menu button for dev menu.',

App/Containers/Root/RootScreen.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@ const AppNav = createStackNavigator(
1818
// Create the application routes here (the key is the route name, the value is the target screen)
1919
// See https://reactnavigation.org/docs/en/stack-navigator.html#routeconfigs
2020
SplashScreen: SplashScreen,
21+
// The main application screen is our "ExampleScreen". Feel free to replace it with your
22+
// own screen and remove the example.
2123
MainScreen: ExampleScreen,
2224
},
2325
{

App/Containers/SplashScreen/SplashScreen.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ export default class SplashScreen extends React.Component {
77
return (
88
<View style={styles.container}>
99
<View style={styles.logo}>
10+
{/* You will probably want to insert your logo here */}
1011
<Text>LOGO</Text>
1112
</View>
1213
</View>

App/Sagas/ExampleSaga.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import { WeatherService } from 'App/Services/WeatherService'
66
* A saga can contain multiple functions.
77
*
88
* This example saga contains only one to fetch the weather temperature.
9+
* Feel free to remove it.
910
*/
1011
export function* fetchTemperature() {
1112
// Dispatch a redux action using `put()`

App/Services/WeatherService.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,12 @@
11
import { create } from 'apisauce'
22
import { Config } from 'App/Config'
33

4+
/**
5+
* This is an example of a service that connects to a 3rd party API.
6+
*
7+
* Feel free to remove this example from your application.
8+
*/
9+
410
const weatherApiClient = create({
511
/**
612
* Import the config from the App/Config/index.js file

App/Stores/Startup/Actions.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import { createActions } from 'reduxsauce'
22

33
const { Types, Creators } = createActions({
4+
// This action is triggered when the application starts
45
startup: null,
56
})
67

0 commit comments

Comments
 (0)