
오른쪽 상단의 초록색 핸드폰 표시 누르기VS Code실행
- LearnReactNative 프로젝트 디렉토리 열기
- Ctrl + ' 눌러서 터미널
- yarn android
- 권한 애러나면 파워쉘 관리자 모드에서
Set-ExecutionPolicy Unrestricted 입력
- 자꾸 아래 애러 떨어짐
error Failed to install the app. Make sure you have the Android development environment set up: https://reactnative.dev/docs/environment-setup.
Error: Command failed: gradlew.bat app:installDebug -PreactNativeDevServerPort=8081
FAILURE: Build failed with an exception.
아래처럼 조치함
yarn upgrade
yarn global add expo-cli
PS C:\WINDOWS\system32> choco install -y openjdk11
결국 그냥 jdk 11깔고 JAVA_HOME C:\Program Files\OpenJDK\jdk-11.0.2 재설정하니 해결
App.js에서 flow 사용 X
const App: () => Node = () => {
const App = () => {
const App = () => {
return(
<SafeAreaView>
<View>
<Text> Hellow React!!!</Text>
</View>
</SafeAreaView>
);
};
export default App;
치면 Hellow React!!! 텍스트 문구 뜸