Skip to content

Commit

Permalink
edit post
Browse files Browse the repository at this point in the history
  • Loading branch information
Jia-Jun Yeh committed Nov 2, 2023
1 parent 0e78a56 commit 8ae0d48
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions _posts/2023-11-02-golang-mapping-strategy.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ func main() {
}
```

這樣做的原因是:response的修改通常是DB和API一起的。而request不總是單純的CRUD,有可能無法對應到response上,所以獨立定義新的struct。這樣的邏輯通常已經能支持中小型專案規模的發展。


## Mapping Strategy
Expand Down

0 comments on commit 8ae0d48

Please sign in to comment.