Directory Structure - programmers-kdt-full-stack-3rd/live-chat GitHub Wiki

디렉토리 ꡬ쑰

Client

client/
β”œβ”€β”€ src/
└── public/

Server

server/
└── src/
    β”œβ”€β”€ config/			# ν™˜κ²½ μ„€μ • (db μ—°κ²° μ„€μ •, nodemailer μ„€μ •, Socket.IO μ„€μ • λ“±)
    β”œβ”€β”€ routes/			# API μ—”λ“œν¬μΈνŠΈ μ •μ˜ 및 μ†ŒμΌ“ 라우트 μ •μ˜
    β”œβ”€β”€ controllers/		# μš”μ²­μ— λŒ€ν•œ μ§„μž…κ³Ό 응닡 λ°˜ν™˜
    β”œβ”€β”€ middlewares/		# Express 미듀웨어 ν•¨μˆ˜(인증, μœ νš¨μ„± 검사 λ“±)  
    β”œβ”€β”€ services/	        # λΉ„μ¦ˆλ‹ˆμŠ€ 둜직  
    β”œβ”€β”€ models(optional)/	# λ°μ΄ν„°λ² μ΄μŠ€ μŠ€ν‚€λ§ˆλ‚˜ λͺ¨λΈ μ •μ˜(ORM μ‚¬μš© μ‹œ)
    β”œβ”€β”€ db(optional)/    	# λ°μ΄ν„°λ² μ΄μŠ€ μ ‘κ·Ό (ORM λ―Έμ‚¬μš©μ‹œ)  
    β”œβ”€β”€ utils/			# μœ ν‹Έλ¦¬ν‹° ν•¨μˆ˜ λͺ¨μŒ(μœ νš¨μ„± 검사 μœ ν‹Έλ¦¬ν‹° ν•¨μˆ˜ λ“±)
    β”œβ”€β”€ app.ts/			# Express μ• ν”Œλ¦¬μΌ€μ΄μ…˜μ˜ μ§„μž…μ  및 μ„€μ •
    └── index.ts/		# μ„œλ²„ μ‹œμž‘μ 