codestates / codestates/withpuppy
[π To Do] μ€νμ / 2021-12-16
- Dominant language
- JavaScript
- Stars
- 0
- Forks
- 3
- PR merge metrics
- No merged PRs in 30d
Description
## βοΈ ν΄μΌ ν μΌ λ¦¬μ€νΈ
μ’μμ κΈ°λ₯ ꡬν TODO
User 1 β (Follow) User 2
UserFollower
Follower(νλ μ¬λ) | User(λ°λ μ¬λ)
-- | --
λ―Έν€ | μ€νμ΄λ맨
λ§μ°μ€ | μ€νμ΄λ맨
λμ μ’μμ μλ μλ€.
User - likes_count
λκ° λλ₯Ό μ’μμνμ§λ λͺ¨λ₯Έλ€.
μ€ν 리
- ν λ§μ»€λ₯Ό λλ λ€.
- κΈ°μ‘΄ μ’μμ μ 보λ₯Ό κ°μ ΈμμΌνλ€.
- μ¬μ©μ : μ€νμ΄λ맨
- νμλ : λ―Έν€
- if λ΄κ° κΈ°μ‘΄μ λλ μλ€λ©΄
SELECT * FROM UserFollower Where Follower=λ―Έν€ User=μ€νμ΄λ맨 β κ²°κ³Ό μ‘΄μ¬- λ³νκ° λλ €μλ€.
- else
SELECT * FROM UserFollower Where Follower=λ―Έν€ User=μ€νμ΄λ맨 β κ²°κ³Ό μμ- λ³νκ° μλλ €μλ€.
- μλ‘κ³ μΉ¨ : 1λ²κ³Ό λμΌ
- λ³νλ₯Ό λλ λ€.
- κΈ°μ‘΄μ μ’μμκ° λλ €μμμΌλ©΄ μ’μμκ° μ·¨μλλ€.
- λ³ν μΉ΄μ΄ν° - 1
- κΈ°μ‘΄μ μ’μμκ° μ λλ €μμμΌλ©΄ μ’μμκ° λΌμΌνλ€.
- λ³ν μΉ΄μ΄ν° + 1
- κΈ°μ‘΄μ μ’μμκ° λλ €μμμΌλ©΄ μ’μμκ° μ·¨μλλ€.
API λμμΈ
- /like GET β κΈ°μ‘΄μ μ’μμλ₯Ό νλκ°
- /like POST β μ’μμ λλ¦
- /like/cancel POST β μ’μμ μΊμ¬
- /like DELETE β μ’μμ μΊμ¬
κ°λ°
- μ΄μμ λͺ©ν : μ λΆ κ°λ°
λ΄ μν
λ‘κ·ΈμΈ κΈ°λ₯ μλ μ¬λΆ λΆλͺ ν
μ μ νΈμΆλΆκ° μ°λλμ΄ μμ§ μμ
μ’μμλ λ§μ§λ§ μ‘μ
!!
- μ μ μ
μ₯μμ λ‘κ·ΈμΈ νκ³ ν λλ₯΄κ³ μ€λ²λ μ΄ νμ
κ³Ό λμμ νλ‘ν μΉ΄λμμ μ΅μ’
μ μΌλ‘ μ‘μ
νλ κ±΄λ° κ·Έ μ λ¨κ³κ° ꡬνμ΄ μ΄λμ λμ΄ μλμ§ λ΄ μμΌμμ 보μ΄μ§κ° μμ
API μ€κ³ μ λ§€νκ³ μ°λλ μ λ§€νλ€
Contributor guide
No contributing guide indexed for this repository
Research direction
No files or tests are named; first map the existing login, user, pin overlay, profile-card, and API entry points described in the issue. Clarify the API design and UserFollower data flow before starting, then verify that the like state and counter persist correctly for both like and cancel actions.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- api, database, full-stack
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100