전체 글 210

[React Native] react native android apk 뽑기

1. apk 뽑는 블로그 그대로 따라했음https://bomjjack.github.io/programming/2018/01/06/rn-android-app-release/ React Native 릴리즈 빌드(안드로이드 편)안드로이드편.bomjjack.github.io  2. apk 뽑기는 성공했는데 api url이 https가 아닌 http 여서 통신이 안됐음.안드로이드 release 버전에서는 http 통신이 기본적으로 안됨. 그래서 설정을 해줘야 함! 해결책 -> github.com/facebook/react-native/issues/24408#issuecomment-537081276 Fetch not working for HTTP requests on Android · Issue #24408 · f..

[React Native] react-native-svg ProgressCircle로 시계 나타내는 법 / startAngle, endAngle

1. 라이브러리 https://github.com/JesperLekland/react-native-svg-charts JesperLekland/react-native-svg-charts 📈 One library to rule all charts for React Native 📊 - JesperLekland/react-native-svg-charts github.com 2. ProgressCircle Usage - 10시~3시, 6시~12시 같은 일정이 있으면 그 시간만큼이 채워진 원형 그래프를 그리고 싶었다. - 딱 적합한 것이 ProgressCircle이었다. - 먼저 문서 그대로 사용해보면 이렇게 보인다. * 코드 * 결과 - 특정 시간대를 이 원형그래프로 나타내려면 어떻게 해야할까? - startA..

[React Native] AppState / detect foreground, background

0. 소개AppState를 이용하면 앱이 background였다가 foreground 상태로 왔는지, 그 반대인지를 알 수 있다.  1. 문서https://reactnative.dev/docs/appstate.html React Native · A framework for building native apps using ReactA framework for building native apps using Reactreactnative.dev 2. Usage앱이 포그라운드 -> 백그라운드 로 가는 순간appState는 active -> inactive -> background로 바뀐다. 이 과정에서 앱이 백그라운드 상태가 되면 setAppState가 매끄럽게 이어져서 appState는 background여..

@react-navigation/routers/src/index.tsx: Unexpected token (9:12) 해결법

https://github.com/react-navigation/react-navigation/issues/8060 @react-navigation/routers/src/index.tsx: Unexpected token (9:12) · Issue #8060 · react-navigation/react-navigationsoftware version iOS or Android @react-navigation/native 5 react-native expo node npm or yarngithub.com나와 같은 오류를 접한 사람이 있었다.  https://github.com/react-navigation/react-navigation/issues/7981#issuecomment-611377210 Build..

[React Native] DeviceInfo 휴대폰에 관한 정보 가져오기 / 휴대폰 기종

라이브러리 https://github.com/react-native-community/react-native-device-info react-native-community/react-native-device-info Device Information for React Native iOS and Android - react-native-community/react-native-device-info github.com 이를 이용하면 휴대폰에 관한 정보를 얻을 수 있다. 내가 자주 사용하는 함수들만 모아보았다. import DeviceInfo, { getApiLevel, getBrand, getVersion, getBuildNumber, getSystemVersion, getUniqueId, getModel,..

[React Native] Firebase 연동 & Cloud Messaging 연동

1. Firebase 연동https://dev-yakuza.github.io/ko/react-native/react-native-firebase-v6-installation/ react-native-firebase V6 설치React Native에서 Firebase를 사용하기 위해 react-native-firebase(V6)을 설치하는 방법에 대해서 알아봅시다.dev-yakuza.github.io- iOS 설치 시 오류react native firebase terminating with uncaught exception of type NSExceptionhttps://github.com/invertase/react-native-firebase/issues/1378GoogleService-Info.pli..

[React Native] Splash Screen 사용법 / 스플래시 LaunchImage

0. 환경react-native: 0.61.5react-native-splash-screen: 3.2.0 1. 설치https://github.com/crazycodeboy/react-native-splash-screen crazycodeboy/react-native-splash-screenA splash screen for react-native, hide when application loaded ,it works on iOS and Android. - crazycodeboy/react-native-splash-screengithub.comnpm i react-native-splash-screen --savecd ios && pod install && cd ..auto link 지원되므로 다른거 할 필..

[React Native] GraphQL & Apollo & Code Generator 사용법

1. 아폴로란?https://www.apollographql.com/docs/react/- Apollo Client는 JavaScript 앱을 위한 상태 관리 라이브러리- GraphQL 쿼리를 작성하기 만하면 Apollo Client가 데이터를 요청하고 캐싱하고 UI를 업데이트한다.- 리덕스와 작별할 수 있다! 2. 설치npm install apollo-boost @apollo/react-hooks graphql react-apolloapollo-boost: Package containing everything you need to set up Apollo Client@apollo/react-hooks: React hooks based view layer integrationgraphql: Also pa..

[React Native] build가 영원히 되지 않을 때

react-native run-ios 를 할 때fail이 아니라 영원히 build가 되지 않을 때가 있다. 원래는 이렇게 빌드가 잘 되어야 하는데 Building 다음에..이 위 사진처럼 많이 생기지 않고 딱 .. 2개만 생기면서 영원히 빌드가 끝나지 않을 때가 있다. => https://github.com/facebook/react-native/issues/15469 [Build][iOS] Building project in Xcode takes for ever in Running 1 of 1 custom shell scripts · Issue #15469 · facebook/react-nHave you read the Contributing Guidelines? yes Environment react..

출처: https://mingos-habitat.tistory.com/34 [밍고의서식지:티스토리]