웹/Node.js & React.js
-
[React] 안드로이드로 react-native 연결하고 카메라 띄우기웹/Node.js & React.js 2022. 4. 26. 13:21
먼저 환경 변수 설정을 해주자 sdk가 위치한 곳을 ANDROID_HOME으로 정하고 path에 platfrom-tools도 환경변수 설정해둠 환경 변수가 잘 설정되면 cmd창에서 잘 나온다. 핸드폰을 노트북에 연결하고 adb devices 명령어로 잘 연결됐는지 확인하고 adb reverse 로 기기의 포트를 8081로 변경해주자 VS code 터미널 실행 npm install --save react-native-camera npm install --save @react-native-community/cameraroll 자동으로 config 코드 추가해주기 react-native link @react-native-community/cameraroll && npx pod-install 터미널에서 실행하니..
-
[React] React-Native로 안드로이드 에뮬레이터 실행하기웹/Node.js & React.js 2022. 4. 25. 20:19
React Native를 사용하기 위해서 - Node.js(Npm) - AndroidStudio - VisualStudioCode 가 필요함 안드로이드 스튜디오 설정하기 1. 시스템 환경변수 설정 File -> settings -> Android SDK 나는 SDK를 d드라이브에 설치했기에 경로가 d드라이브로 되어있다. sdk 설치경로를 복사하여 시스템 환경변수를 설정해주자 2. sdk 설치 react-native는 API 버전 29에서 (Android 10.0(Q)) 잘 돌아간다. 따라서 sdk 버전을 29에 맞게 설치해주면 됨 [show package details] 눌러서 사진에 있는 항목들을 따로 설치하자 3. AVD manager 안드로이드 스튜디오에서 adv 에뮬레이터를 실행하자 api 버전(..
-
[Node&React] 오류웹/Node.js & React.js 2022. 3. 16. 20:01
https://stackoverflow.com/questions/57054403/problem-with-npm-start-error-spawn-cmd-enoent Problem with npm start (error : spawn cmd ENOENT) I have a problem with my application. Because before when I created an application it worked, but now, it shows me this error and I do not know why and the things I have to do to fix it. Do you ha... stackoverflow.com node:events:498 throw er; // Unhandled ..
-
[React.js] 리액트를 이용해서 회원가입 페이지 만들기웹/Node.js & React.js 2022. 2. 13. 15:10
- React는 module과 비슷한 component로 이루어지고 재사용이 뛰어남 - Virtual DOM : RealDOM : 한 부분이 바뀌어도 전체 리스트를 reload 해야 함 : Virtual DOM : 한 부분이 바뀌어도 바뀐 부분 리스트만 update 해도 됨, snapshot을 이용해서 바뀐 부분을 관찰함 - create-react-app으로 리액트 시작 : 원래 리액트 앱을 처음 실행 하기 위해선 webpack이나 babel을 설정해야함 : babel - 최신 자바스크립트 문법을 지원하지 않는 브라우저들을 위해서 최신 자바스크립트 문법을 구형 브라우저에서도 돌수있게 변형시켜줌 : webpack - webpack을 이용해서 bundle화 - npx create-react-app . : 원..
-
[Node.js] postman을 이용하여 회원가입 기능 구현하기웹/Node.js & React.js 2022. 2. 12. 01:00
- 명령 프롬프트 창에 node 설치 - node.js의 프레임워크인 express 설치 - mongoDB, mongoose 설치 - ssh 키 생성하여 github에 ssh키 설정 - 서버올리기 : npm start run ( run은 package.json에서 내가 임의로 설정해줌) - nodemon(서버 변경상태 실시간 감지) : npm start backend ( backend는 package.json에서 내가 임의로 설정해줌) package.json - 설치된 패키지들을 관리 - start시, index.js가 먼저 실행되게 함 { "name": "boiler-plate", "version": "1.0.0", "description": "", "main": "index.js", "scripts"..