Difference between revisions of "Expo"
Jump to navigation
Jump to search
(One intermediate revision by the same user not shown) | |||
Line 23: | Line 23: | ||
Untuk navigasi antar pages | Untuk navigasi antar pages | ||
expo install react-native-screens react-native-safe-area-context | expo install react-native-screens react-native-safe-area-context | ||
+ | expo install react-native-gesture-handler react-native-reanimated react-native-screens react-native-safe-area-context @react-native-community/masked-view | ||
+ | |||
+ | npm install @react-navigation/native --save | ||
+ | npm install @react-navigation/stack --save | ||
+ | npm install react-native-webview @react-navigation/native @react-navigation/stack react-native-gesture-handler | ||
+ | |||
+ | Menggunakan yarn (berhasil) | ||
+ | yarn add @react-navigation/native-stack | ||
===QR Code=== | ===QR Code=== | ||
Line 28: | Line 36: | ||
expo install expo-barcode-scanner | expo install expo-barcode-scanner | ||
+ | ===Axios=== | ||
+ | Untuk API dapat menggunakan axios | ||
+ | npm install axios | ||
==Pranala menarik== | ==Pranala menarik== |
Latest revision as of 17:22, 21 July 2022
Contents
Instalasi
npm install --global expo-cli
Membuat project baru
expo init my-project
Jika ingin menggunakan device asli, bisa install Expo Go, atau nanti akan diinstall ketika akan dijalankan (device tersambung). Cek device yang terhubung dengan
adb devices
Running aplikasi
Masuk ke folder
cd my-project yarn start
Instalasi Library
Untuk navigasi antar pages
expo install react-native-screens react-native-safe-area-context expo install react-native-gesture-handler react-native-reanimated react-native-screens react-native-safe-area-context @react-native-community/masked-view
npm install @react-navigation/native --save npm install @react-navigation/stack --save npm install react-native-webview @react-navigation/native @react-navigation/stack react-native-gesture-handler
Menggunakan yarn (berhasil)
yarn add @react-navigation/native-stack
QR Code
Untuk membaca QR code
expo install expo-barcode-scanner
Axios
Untuk API dapat menggunakan axios
npm install axios