Project/codestates-final-project 29

18.5일차 / socket.io 적용

socket.io에 대해 내가 쓴 글 https://fullfish.tistory.com/115 socket.io socket.io를 이용해서 실시간 채팅 구현하기 서버 코드 //index.js var app = require('express')(); var server = require('http').createServer(app); // http server를 socket.io server로 upgrade한다 var io.. fullfish.tistory.com 사용예시 서버 코드 //index.js const hashtag_delete_schedule = require("./controllers/diary/hashtag_delete_schedule"); require("dotenv").config(..

18일차 / google map api

google map api에 대해 내가 쓴 글 https://fullfish.tistory.com/111 구글 맵 API https://console.cloud.google.com/google/maps-apis/start?hl=ko Google Cloud Platform 하나의 계정으로 모든 Google 서비스를 Google Cloud Platform을 사용하려면 로그인하세요. accounts.google.com 우선 해.. fullfish.tistory.com 위 게시물의 기본적인 코드는 지정된 경도 위도값만을 불러오는것인데 현재 프로젝트에서의 구글맵의 쓰임새는 가계부 작성시 자동으로 gps값이 db에 저장되며 나중에 해당 가계부 조회시 물건을 산 장소을 알 수 있게끔 하는것이다 그러므로 가계부 페이지..

17일차 / n-Gram구현 및 개선, 리벤슈타인 거리 시간,공간 복잡도 개선

n-Gram n-gram에 대해 내가 쓴 글들 https://fullfish.tistory.com/109 n-Gram n-Gram이란 문장의 유사도를 비교하는 방법중 하나로 문장을 쪼개서 비교한다 예를 들어 3-gram으로 '과자중에 제일 맛있는건 새우깡' '제일 맛있는 과자는 무엇일까' 이 두문장을 비교한다면 각 문 fullfish.tistory.com https://fullfish.tistory.com/110 n-Gram 개선 및 고찰 자음 모음단위로 n-Gram 저번에 구현한 n-gram https://fullfish.tistory.com/109 n-Gram n-Gram이란 문장의 유사도를 비교하는 방법중 하나로 문장을 쪼개서 비교한다 예를 들어 3-gram으로 '과자중에 제일 맛있.. fullfi..

15일차 / fuzzy검색의 highlight와 가중치 적용

한것 Highlight 적용 검색을 한 글자를 빨간색으로 반환 가중치 적용 원래 db상 '과일먹자'가 '과자냠냠'보다 id값이 빨라서 상단에 위치했는데 유저가 좀더 찾기를 원했을만한 단어가 위로가게 가중치 적용 highlight와 가중치에 대해 내가 쓴 글 https://fullfish.tistory.com/105 fuzzy검색의 highlight와 가중치 적용 참고 : https://taegon.kim/archives/9919 [JS] 한글도 지원하는 퍼지 문자열 검색 UI 작업을 하다보면 목록을 검색해야 할 때가 많다. 그런데 사람의 기억이라는 게 정확하지 않아서 혹은 전부 입력하기 귀 fullfish.tistory.com result = document.querySelectorAll('.title'..

14일차 / 배포 (https, 도메인), 프론트 search창

https로 서버를 배포했다 배포 참고 : https://fullfish.tistory.com/53?category=1050721 4일차 / HTTPS인증과 도메인구입 (route53) 진행 백앤드 https 인증과 route53으로 도메인을 바꿨다 프론트와 백모두 AWS상에서 hello world 출력 성공 https인증은 AWS에서 로드밸런서를 이용해서 적용함 하는법(주의할점만) 로드밸런서 생성 Interne fullfish.tistory.com https://just-moment-trip.tk 로 도메인을 만들었다 프론트 search창을 만드는데 기여했다

13일차 / fuzzy검색 구현

다이어리의 title이 위 이미지처럼 14개가 있을 때 "새깡"으로 검색시 { "data": [ { "id": 3, "title": "과자는새우깡", "picture": "url", "gps": "21,22", "content": "새우깡은갈매기꺼", "write_date": "2022-12-01 09:00:00", "createdAt": "2022-05-05 22:26:02", "updatedAt": "2022-05-05 22:26:02", "trip_id": 1, "hashtags": [ "맛있다", "새우새우", "냠" ] }, { "id": 4, "title": "새우깡은과자", "picture": "url", "gps": "21,22", "content": "새우깡은갈매기꺼", "write_da..

11일차 / N : M연결 diary와 hashtag 작성 및 scheduler를 이용한 쓰레기값 삭제

어제 팬딩이 뜨는상황은 promise로하면 해결이 되긴하지만 다른문제들 때문에 맨 처음했던 방법으로 돌아갔다 진행한 내용은 따로 정리해 뒀다 Sequelize 기본 설정 : https://fullfish.tistory.com/91?category=1054038 Sequelize와 Migration 기본 설정 Migration을 하면 데이터베이스에 테이블 생성 및 삭제할것을 미리 선언해두는것이고 Seed는 그 테이블에 더미데이터를 집어 넣는거 공식문서 : https://sequelize.org/docs/v6/other-topics/migrations/ Migratio.. fullfish.tistory.com Sequelize 관계 설정 : https://fullfish.tistory.com/92?categ..

10일차 / n : m 연결 고민 미완이라 내일도 할 예정

원래 diary post 코드 try { const { title, picture, gps, content, write_date, hashtags } = req.body; if (!title || !picture || !content || !write_date) { await slack.slack("Diary Post 422"); return res.status(422).send({ message: "insufficient parameters supplied" }); } const validity = await tokenHandler.accessTokenVerify(req, res); if (validity) { //해쉬태그 제외한 다이어리 추가 const diaryPayload = { trip_id: ..