Skip to content

seacrab808/Fastmind-server

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

16 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

ํŒจ์ŠคํŠธ์บ ํผ์Šค ํ† ์ดํ”„๋กœ์ ํŠธ2 ํ•œ์กฐํŒ€์˜ FastMind ๊ฒŒ์ž„ ๐Ÿ’ป ๋ฐฑ์—”๋“œ

wiki


๐Ÿ“ ํ”„๋กœ์ ํŠธ ์†Œ๊ฐœ

FastMind๋Š” ์ฐฝ์˜์ ์ด๊ณ  ์ƒํ˜ธ์ž‘์šฉ์ด ํ’๋ถ€ํ•œ ์›น ์• ํ”Œ๋ฆฌ์ผ€์ด์…˜์ž…๋‹ˆ๋‹ค. ์ด ํ”„๋กœ์ ํŠธ๋Š” ๊ทธ๋ฆผํŒ๊ณผ ๊ฒŒ์ž„, ์ฑ„ํŒ… ๊ธฐ๋Šฅ์„ ํ†ตํ•ฉํ•˜์—ฌ ์•„๋ž˜ ๋‘ ๊ฐ€์ง€ ์ฃผ์š” ๋ฐฉ์‹์œผ๋กœ ์‚ฌ์šฉ๋ฉ๋‹ˆ๋‹ค.

  1. ๊ฒŒ์ž„ ๋ชจ๋“œ: ์‚ฌ์šฉ์ž ์ค‘ ํ•œ ๋ช…์ด ์ถœ์ œ์ž๊ฐ€ ๋˜์–ด, ํ€ด์ฆˆ๋ฅผ ๋‚ด๊ณ  ๊ด€๋ จ๋œ ๊ทธ๋ฆผ์„ ๊ทธ๋ฆฝ๋‹ˆ๋‹ค. ๊ทธ ํ›„, ๋‹ค๋ฅธ ์ฐธ์—ฌ์ž๋“ค์ด ๊ทธ๋ฆผ์„ ๋ฐ”ํƒ•์œผ๋กœ ํ€ด์ฆˆ์˜ ๋‹ต์„ ๋งž์ถ”๋Š” ๋Œ€ํ™”ํ˜• ์›น ๊ฒŒ์ž„์ž…๋‹ˆ๋‹ค.
  2. ํ˜‘์—… ๋ชจ๋“œ: ์‚ฌ์šฉ์ž๋“ค์€ ๊ทธ๋ฆผํŒ์— ์ง์ ‘ ๊ทธ๋ฆผ์„ ๊ทธ๋ฆฌ๋ฉฐ, ์‹ค์‹œ๊ฐ„์œผ๋กœ ๊ณต์œ ํ•˜๊ณ  ์ฑ„ํŒ…์„ ํ†ตํ•ด ์•„์ด๋””์–ด๋ฅผ ๊ตํ™˜ํ•ฉ๋‹ˆ๋‹ค. ์ด ๋ชจ๋“œ๋Š” ํšŒ์˜, ๋ธŒ๋ ˆ์ธ์Šคํ† ๋ฐ, ๋˜๋Š” ์ผ๋ฐ˜ ๋Œ€ํ™”์— ์ด์ƒ์ ์œผ๋กœ ํ™œ์šฉ๋ฉ๋‹ˆ๋‹ค.

ํ”„๋ก ํŠธ์—”๋“œ๋Š” ์ด๊ณณ์„ ํด๋ฆญํ•ด ์ฃผ์„ธ์š”.
์ฑ„ํŒ… ์„œ๋ฒ„๋Š” ์ด๊ณณ์„ ํด๋ฆญํ•ด ์ฃผ์„ธ์š”.
ํ”ผ๊ทธ๋งˆ๋Š” ์ด๊ณณ์„ ํด๋ฆญํ•ด ์ฃผ์„ธ์š”.


๐Ÿ› ๏ธ ๊ธฐ์ˆ  ์Šคํƒ

FrontEnd

Development

React Chakra Recoil StyledComponents Axios

CI/CD

Vercel

Design

Figma

Chatting BackEnd

Language

NodeJS

Framework

Express

DB

MongoDB

Infra

Nginx JWT Socket.io Mongoose

CI/CD

GitHub Actions Amazon EC2

Game BackEnd

Language

NodeJS

Framework

Express

Infra

Socket.io Babel


๐Ÿ“š ์ฃผ์š” ๋กœ์ง

๊ทธ๋ฆผํŒ
  • Canvas API: ๋ณธ ํ”„๋กœ์ ํŠธ์˜ ๊ทธ๋ฆผํŒ ๊ธฐ๋Šฅ์€ HTML5์˜ Canvas API๋ฅผ ํ™œ์šฉํ•˜์—ฌ ๊ตฌํ˜„๋˜์—ˆ์Šต๋‹ˆ๋‹ค.
  • ์‹ค์‹œ๊ฐ„ ํ†ต์‹ : ์‹ค์‹œ๊ฐ„ ์‚ฌ์šฉ์ž ์ƒํ˜ธ์ž‘์šฉ์„ ์œ„ํ•ด Socket.io๋ฅผ ์‚ฌ์šฉํ•˜์˜€์œผ๋ฉฐ, ์‚ฌ์šฉ์ž ๊ฐ„์˜ ๊ทธ๋ฆผ ๋ฐ์ดํ„ฐ ๊ณต์œ  ๋ฐ ํ†ต์‹ ์„ ์œ„ํ•ด ์ž์ฒด์ ์œผ๋กœ ๊ตฌ์ถ•ํ•œ ๋ฐฑ์—”๋“œ ์„œ๋ฒ„์— ์—ฐ๊ฒฐํ•ฉ๋‹ˆ๋‹ค.
  • ์„œ๋ฒ„ ๋ฐฐํฌ: ํ”„๋กœ์ ํŠธ์˜ ๋ฐฑ์—”๋“œ ์„œ๋ฒ„๋Š” Heroku๋ฅผ ํ†ตํ•ด ๋ฐฐํฌ๋˜์—ˆ์Šต๋‹ˆ๋‹ค. node.js/Express/Babel ๋“ฑ์„ ์‚ฌ์šฉํ–ˆ์Šต๋‹ˆ๋‹ค.
์ฃผ์š” ๊ธฐ๋Šฅ
  • ์ƒ‰์ƒ ์„ ํƒ: ์‚ฌ์šฉ์ž๋Š” ๋‹ค์–‘ํ•œ ์ƒ‰์ƒ ํŒ”๋ ˆํŠธ์—์„œ ๋งˆ์Œ๋Œ€๋กœ ์ƒ‰์„ ์„ ํƒํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.
  • ๊ทธ๋ฆฌ๊ธฐ ๋„๊ตฌ: ๋ถ€๋ถ„ ์ง€์šฐ๊ฐœ์™€ ์ „์ฒด ์ง€์šฐ๊ธฐ ๊ธฐ๋Šฅ์„ ํ†ตํ•ด ์‚ฌ์šฉ์ž๋Š” ์‰ฝ๊ฒŒ ๊ทธ๋ฆผ์„ ์ˆ˜์ •ํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.
  • ๊ตต๊ธฐ ์กฐ์ ˆ: ์‚ฌ์šฉ์ž๋Š” ์„ ์˜ ๊ตต๊ธฐ๋ฅผ ์ž์œ ๋กญ๊ฒŒ ์กฐ์ ˆํ•˜์—ฌ ๋‹ค์–‘ํ•œ ํ‘œํ˜„์„ ํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

๊ทธ๋ฆผํŒ์—์„œ์˜ ์‚ฌ์šฉ์ž ์ž‘์—…์€ ๋‹ค์Œ๊ณผ ๊ฐ™์€ ํ˜•์‹์œผ๋กœ ์„œ๋ฒ„๋กœ ์ „์†ก๋ฉ๋‹ˆ๋‹ค.

originalMousePosition: {
  x: number;
  y: number;
};
  newMousePosition: {
  x: number;
  y: number;
};
  option: {
    color: string;
    lineWidth: number;
    roomId: string;
  };
  • originalMousePosition: ํ˜„์žฌ ๋งˆ์šฐ์Šค ์œ„์น˜ (x, y ์ขŒํ‘œ)
  • newMousePosition: ์ƒˆ๋กœ์šด ๋งˆ์šฐ์Šค ์œ„์น˜ (x, y ์ขŒํ‘œ)
  • option: ์ž‘์—… ์˜ต์…˜ (์„ ํƒ๋œ ์ƒ‰์ƒ, ์„ ์˜ ๊ตต๊ธฐ, ๋ฐฉ ID)
๊ฒŒ์ž„ ๋กœ์ง
  • ์œ ์ € ์ง„์ž… ์‹œ ๊ฒŒ์ž„ ์†Œ์ผ“์— ์—ฐ๊ฒฐํ•˜๊ณ  roomId๋ฅผ ๊ธฐ์ค€์œผ๋กœ ๋ฐฉ์„ ์„ ์ •ํ•ด ์œ ์ €๋ฅผ ๋‚˜๋ˆ•๋‹ˆ๋‹ค.
  • ๊ฒŒ์ž„ ์‹œ์ž‘ ๋ฒ„ํŠผ ํด๋ฆญ ์‹œ ํ€ด์ฆˆ ๋ฐฐ์—ด์˜ roomId๋ฒˆ ์ธ๋ฑ์Šค์— ํด๋ฆญํ•œ ํด๋ผ์ด์–ธํŠธ์˜ ์ฟ ํ‚ค ๋‚ด userId๋ฅผ ์ง€์ •ํ•ฉ๋‹ˆ๋‹ค.
  • ๊ฒŒ์ž„ ์‹œ์ž‘ ๋ฒ„ํŠผ ํด๋ฆญ ํ›„ ๋ชจ๋‹ฌ ๋‚ด ๋‹ต์•ˆ ์ž…๋ ฅ ์‹œ ์ •๋‹ต ๋ฐฐ์—ด์˜ roomId๋ฒˆ ์ธ๋ฑ์Šค์— ์ •๋‹ต์„ ์„ค์ •ํ•ฉ๋‹ˆ๋‹ค.
  • ์ฑ„ํŒ…์„ ์นœ ์œ ์ €, ์ฑ„ํŒ… ๊ฐ’, roomId์™€ ์ฟ ํ‚ค ๋‚ด userId์„ ์„œ๋ฒ„์— ๋ณด๋ƒ…๋‹ˆ๋‹ค.
  • ๋งŒ์•ฝ ๋‹ต๋ณ€์„ ํ•œ ์œ ์ €๊ฐ€ ํ€ด์ฆˆ ๋ฐฐ์—ด์˜ roomId๋ฒˆ ์ธ๋ฑ์Šค์™€ ๋‹ค๋ฅด๊ณ  ๋‹ต๋ณ€์„ ํ•œ ์œ ์ €์˜ ๋‹ต์•ˆ์ด ์ •๋‹ต ๋ฐฐ์—ด์˜ roomId๋ฒˆ ์ธ๋ฑ์Šค์™€ ๊ฐ™๋‹ค๋ฉด, ์ถœ์ œ์ž๊ฐ€ ์•„๋‹ˆ๋ฉด์„œ ๋‹ต๋ณ€์„ ๋งžํ˜”๋‹ค๋Š” ๋œป์ด๋ฏ€๋กœ ํ•ด๋‹น ํ•˜๋Š” ๋ฐฉ ๋‚ด ๋ชจ๋“  ํด๋ผ์ด์–ธํŠธ๋“ค์—๊ฒŒ ์Šน์ž๋ฅผ ์„ ์ •ํ•ด ๋ฐ์ดํ„ฐ๋ฅผ ๋ณด๋ƒ…๋‹ˆ๋‹ค.
  • ๋‹ค์Œ ๊ฒŒ์ž„์„ ์œ„ํ•ด ์„œ๋ฒ„์—์„œ๋Š” ํ•ด๋‹นํ•˜๋Š” roomId๋ฒˆ ์ธ๋ฑ์Šค์˜ ํ€ด์ฆˆ ๋ฐฐ์—ด๊ณผ ์ •๋‹ต ๋ฐฐ์—ด์„ ์ดˆ๊ธฐํ™” ํ•ด์ค๋‹ˆ๋‹ค.
  • ์Šน์ž ๋ฐ์ดํ„ฐ๊ฐ€ ์ฟ ํ‚ค ๋‚ด userId์™€ ๊ฐ™๋‹ค๋ฉด ์ •๋‹ต์„ ๋งžํ˜”๋‹ค๋Š” ๋ชจ๋‹ฌ์„ ๋„์›Œ์ค๋‹ˆ๋‹ค.
  • ๋‹ค๋ฅด๋‹ค๋ฉด ํƒ€ ์œ ์ €๊ฐ€ ์ •๋‹ต์„ ๋งžํ˜”๋‹ค๋Š” ๋ชจ๋‹ฌ์„ ๋„์›Œ์ค๋‹ˆ๋‹ค.
  • ์ด ํ›„, ๊ฒŒ์ž„ ์‹œ์ž‘ ๋ฒ„ํŠผ ํด๋ฆญ ์‹œ ๊ฒŒ์ž„์ด ์žฌ์‹œ์ž‘ ๋ฉ๋‹ˆ๋‹ค.
  • โฐ ๊ฒŒ์ž„ ์ค‘, ์–ธ์ œ๋“  ๊ฒŒ์ž„ ์‹œ์ž‘ ๋ฒ„ํŠผ์„ ๋ˆŒ๋Ÿฌ๋„, ํ•ด๋‹นํ•˜๋Š” roomId๋ฒˆ ์ธ๋ฑ์Šค์˜ ์ •๋‹ต ๋ฐฐ์—ด ๋ฐ ํ€ด์ฆˆ ๋ฐฐ์—ด์˜ ๋ฎ์–ด์”Œ์›€์œผ๋กœ ์–ธ์ œ๋“  ์žฌ ์‹œ์ž‘์ด ๊ฐ€๋Šฅํ•ฉ๋‹ˆ๋‹ค.

๐Ÿ–Œ๏ธ ํ”„๋กœ์ ํŠธ ์•„ํ‚คํ…์ฒ˜



๐Ÿง‘๐Ÿปโ€๐Ÿ’ป ํŒ€ ์†Œ๊ฐœ

์žฅํ˜ธ์ง„ (FE & BE) ์–‘์žฌํ˜ (FE & BE) ์†Œ์œ ๋‚˜ (FE & BE)
leHiHo yangjaehyuk seacrab808
  • ๊ฒŒ์ž„ ๋กœ์ง
  • ๊ฒŒ์ž„ ์†Œ์ผ“
  • ๋ฐฐํฌ
  • ๊ฒŒ์ž„ ๋กœ์ง
  • ๊ฒŒ์ž„ ์†Œ์ผ“
  • ๊ทธ๋ฆผํŒ ์†Œ์ผ“
  • ๊ฒŒ์ž„ ์„œ๋ฒ„

๐Ÿ“† ๊ธฐ๊ฐ„

2023.11.06 ~ 2023.11.17

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •