일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | 6 | |
7 | 8 | 9 | 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | 18 | 19 | 20 |
21 | 22 | 23 | 24 | 25 | 26 | 27 |
28 | 29 | 30 |
- nextjs-performance
- create-next-app
- 호텔 대실
- 리액트네이티브
- 귤 고르기
- Leetcode #javascript #알고리즘 #Algorithms #js
- 중첩 점
- mutationobserver
- 테스트 Date
- ResizeObserver
- Google 애널리틱스
- 과제 진행하기
- Hermes Engine
- 헤르메스 엔진
- 프로그래머스
- 구름톤챌린지
- 리액트네이티브 엔진
- 통신망분석
- mock date
- 구름톤
- 구름톤 챌린지
- jest
- 최솟갑 구하기
- 자바스크립트
- nextjs
- Jest uuid syntax
- 테이블 해시 함수
- JavaScript
- 연결 요소 제거하기
- 날짜 테스트
- Today
- Total
목록Web Development/Back (6)
나만보는개발공부블로그
Jest를 통해 테스트를 작성할때 Date() 객체와 관련된 데이터들의 시간을 임의로 설정해서 테스트를 해야하는 상황이 생길 수 있다. 이러한 경우, new Date()함수를 jest.fn()을 통해서 임의로 실행된 node환경에서의 Date()의 시간을 내가 원하는 시간대로 설정할 수 있다. Jest version 26을 기점으로 작성하는 방식이 다른데 const mockDate = new Date(2022,11,22); //version 26이상 jest .useFakeTimers() .setSystemTime(mockDate); //version 26이하 //before test const spy = jest .spyOn(global, 'Date') .mockImplementation((...arg..
NestJS란? 확장성 가능한 NodeJS기반의 서버 프레임워크이다. Typescript를 기본적으로 지원하고 OOP기반과 FP 그리고 FRP의 요소들을 조합한다. 내부적으로 Fastify를 선택적으로 구성할 수 있고 기본적으로 Express와 같은 강력한 HTTP 서버 프레임워크를 사용한다. * Fastify를 사용할려면 Adapter를 이용해야하는데 특정 모듈을 아래와 같이 설치하고 앱을 구성할때 FastifyAdapter 를 사용하면 된다. npm i --save @nestjs/platform-fastify 실습해보기 먼저 nestjs/cli를 설치해서 nestjs 구조를 쉽게 구성할 수 있다. npm i -g @nestjs/cli nest new project-name 생성을 완료하게 되면 src..
grant all privileges on *.* to 'root'@'%' identified by '비밀번호' mysql -u root -p 비번입력 1. MariaDB 설치 - yum repository 등록 [mariadb] name = MariaDB baseurl = http://yum.mariadb.org/10.4/centos7-amd64 gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB gpgcheck=1 - yum install 진행 yum install MariaDB -mariadb 실행 systemctl start mariadb 터미널재접속후 mysqladmin -u root password '설정할 비번' -MariaDB 실행해보기 mysql ..
cd 백엔드경로 cd /백엔드경로 1. node 설치 yum install -y nodejs 2. pm2 설치 - npm을 통해서 global option을 주고 어디서든 실행 할 수 있도록 설정하여 설치 npm install -g pm2 3. 백엔드 서버 배포 - webpack 및 build 과정을 생략하고 백엔드 파일을 stfp을 통해 server로 전송. ex) /usr/mysite/back cd 백엔드경로 pm2 start 파일

1. React build 실행 & 서버로 파일 옮기기 npm run build 이 build 폴더를 nginx 경로에 설정해줘야한다. 내가 원하는 경로에 build 폴더를 옮겨주자. ex) /usr/mysite/front - build폴더를 서버에 옮기는 방법은 나의 경우 solar-putty를 다운받아서 sftp 옮겼다. www.solarwinds.com/ko/free-tools/solar-putty Solar-PuTTY for Windows – Free SSH Download | SolarWinds Find and resolve application or server problems before they become incidents 1200+ application performance monito..
Nginx 설치 systemctl enable nginx yum install -y nginx - nginx 저장소가 없을시 sudo vi /etc/yum.repos.d/nginx.repo 이후에 baseurl 내용에 os version에 맞게 설정 [nginx] name=nginx repo baseurl=http://nginx.org/packages/centos/7/$basearch/ gpgcheck=0 enabled=1 http 방화벽 설정 sudo firewall-cmd --permanent --zone=public --add-service=http sudo firewall-cmd --reload 만약 FirewallD is not running error systemctl start firewal..