This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
node -v > .nvmrc |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
La commande `react-native run-android --variant=release` génère directement un APK dans le dossier `android/app/build/outputs/apk/release/app-release.apk` | |
Google donne la possibilité maintenant de générer des .aab qui sont beaucoup plus légers et qui sont donc préférables | |
Pour en générer: | |
`cd android/` | |
`./gradlew bundleRelease` | |
Cette commande va générer un AAB dans le dossier `android/app/build/outputs/bundle/release/app.aab` |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import * as React from "react" | |
import { View, Text } from "react-native" | |
import { NavigationScreenProps } from "react-navigation" // <=== | |
export interface Props extends NavigationScreenProps<{}> { // <=== | |
propsVar: any; | |
} | |
export interface State { | |
stateVar: any; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
watchman shutdown-server | |
brew update | |
brew reinstall watchman |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Pour tester le projet sur un device: | |
1 - CMD + MAJ + B | |
2 - Player settings | |
3 - Dans "Publishing settings", mettre le mdp pour | |
'keystore password' | |
'Password' (pour le alias de la Key) | |
Mot de passe classique en i | |
4 - Dans la popup de CMD + MAJ + B, cocher: | |
'Build App Bundle (Google Play)' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Take a screenshot from an Android device connected: | |
1 - Takes the screenshot | |
2 - Pull the screenshot from the device to the computer | |
3 - Deletes the screenshot on the device | |
For a file named `screen.png` | |
`adb shell screencap -p /sdcard/screen.png && adb pull /sdcard/screen.png && adb shell rm /sdcard/screen.png` |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Show hidden characters
{ | |
"presets": ["module:metro-react-native-babel-preset"], | |
"env": { | |
"production": { | |
} | |
}, | |
"plugins": [ | |
[ | |
"transform-inline-environment-variables", | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import "./i18n" | |
import * as React from "react" | |
import { AppRegistry } from "react-native" | |
import { StatefulNavigator } from "./navigation" | |
import { StorybookUIRoot } from "../storybook" | |
import { RootStore, setupRootStore } from "./models/root-store" | |
import { Provider } from "mobx-react" | |
import { BackButtonHandler } from "./navigation/back-button-handler" | |
import { contains } from "ramda" | |
import { DEFAULT_NAVIGATION_CONFIG } from "./navigation/navigation-config" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.boilerplatetest; | |
import com.facebook.react.ReactActivity; | |
import android.os.Bundle; | |
import com.facebook.react.ReactActivityDelegate; | |
import com.facebook.react.ReactRootView; | |
import com.swmansion.gesturehandler.react.RNGestureHandlerEnabledRootView; | |
import org.devio.rn.splashscreen.SplashScreen; |
NewerOlder