From fc9f65cf8470c2d9402bb58b548a57ef12ba6600 Mon Sep 17 00:00:00 2001 From: oginoshikibu Date: Fri, 6 Sep 2024 23:06:18 +0900 Subject: [PATCH 01/14] =?UTF-8?q?router=E3=81=AE=E8=A8=AD=E5=AE=9A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- backend/main.go | 10 +++++----- backend/routes/router.go | 29 +++++++++++++++++++++++++++++ 2 files changed, 34 insertions(+), 5 deletions(-) create mode 100644 backend/routes/router.go diff --git a/backend/main.go b/backend/main.go index 003efd7..a6ac575 100644 --- a/backend/main.go +++ b/backend/main.go @@ -7,12 +7,12 @@ import ( ) func main() { - r := gin.Default() - - r.GET("/", func(c *gin.Context) { + router := routes.GetRouter() + router.GET("/", func(c *gin.Context) { c.JSON(http.StatusOK, gin.H{ - "message": "Hello World", + "message": "Hello, World!!", }) }) - r.Run() // listen and serve on 0.0.0.0:8080 (for windows "localhost:8080") + + router.Run(":8080") } diff --git a/backend/routes/router.go b/backend/routes/router.go new file mode 100644 index 0000000..dbeed6f --- /dev/null +++ b/backend/routes/router.go @@ -0,0 +1,29 @@ +package routes + +import ( + "github.com/gin-gonic/gin" +) + +func GetRouter() *gin.Engine { + router := gin.Default() + + api := router.Group("/api/v1") + { + users := api.Group("/users") + { + users.GET("/", func(c *gin.Context) { + c.JSON(200, gin.H{ + "message": "All users", + }) + } + ) + } + + friends := api.Group("/friends") + { + } + + } + + return router +} \ No newline at end of file From fce53f67e546370069ce42c28f2260f2fe9ccdc0 Mon Sep 17 00:00:00 2001 From: oginoshikibu Date: Fri, 6 Sep 2024 23:53:54 +0900 Subject: [PATCH 02/14] Update module name to "backend" --- backend/go.mod | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/go.mod b/backend/go.mod index a37ae39..77de478 100644 --- a/backend/go.mod +++ b/backend/go.mod @@ -1,4 +1,4 @@ -module sample +module backend go 1.22.6 From e0925ff661cc261fe503c47ef237a6655a0dd280 Mon Sep 17 00:00:00 2001 From: oginoshikibu Date: Fri, 6 Sep 2024 23:54:49 +0900 Subject: [PATCH 03/14] Remove unused test code --- backend/main.go | 8 +------- backend/routes/router.go | 7 +------ 2 files changed, 2 insertions(+), 13 deletions(-) diff --git a/backend/main.go b/backend/main.go index a6ac575..463e24c 100644 --- a/backend/main.go +++ b/backend/main.go @@ -3,16 +3,10 @@ package main import ( "net/http" "github.com/gin-gonic/gin" - _ "github.com/lib/pq" + "backend/routes" ) func main() { router := routes.GetRouter() - router.GET("/", func(c *gin.Context) { - c.JSON(http.StatusOK, gin.H{ - "message": "Hello, World!!", - }) - }) - router.Run(":8080") } diff --git a/backend/routes/router.go b/backend/routes/router.go index dbeed6f..3132d17 100644 --- a/backend/routes/router.go +++ b/backend/routes/router.go @@ -11,17 +11,12 @@ func GetRouter() *gin.Engine { { users := api.Group("/users") { - users.GET("/", func(c *gin.Context) { - c.JSON(200, gin.H{ - "message": "All users", - }) - } - ) } friends := api.Group("/friends") { } + } } From 66a7d1e13d73ad8a32e7f73323393f18b7601306 Mon Sep 17 00:00:00 2001 From: oginoshikibu Date: Sat, 7 Sep 2024 15:09:57 +0900 Subject: [PATCH 04/14] Update module name to "gomoku" --- backend/go.mod | 2 +- backend/main.go | 4 +--- backend/routes/router.go | 1 + 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/backend/go.mod b/backend/go.mod index 77de478..ca200dd 100644 --- a/backend/go.mod +++ b/backend/go.mod @@ -1,4 +1,4 @@ -module backend +module gomoku go 1.22.6 diff --git a/backend/main.go b/backend/main.go index 463e24c..16c260d 100644 --- a/backend/main.go +++ b/backend/main.go @@ -1,9 +1,7 @@ package main import ( - "net/http" - "github.com/gin-gonic/gin" - "backend/routes" + "gomoku/routes" ) func main() { diff --git a/backend/routes/router.go b/backend/routes/router.go index 3132d17..da3c777 100644 --- a/backend/routes/router.go +++ b/backend/routes/router.go @@ -2,6 +2,7 @@ package routes import ( "github.com/gin-gonic/gin" + "gomoku/controllers" ) func GetRouter() *gin.Engine { From f200ea06a3a55f9bbb65bf81f07495a145f17d77 Mon Sep 17 00:00:00 2001 From: oginoshikibu Date: Sat, 7 Sep 2024 15:41:47 +0900 Subject: [PATCH 05/14] Add login controller and route for login functionality --- backend/controllers/login_controller.go | 21 +++++++++++++++++++++ backend/routes/router.go | 10 +++++----- 2 files changed, 26 insertions(+), 5 deletions(-) create mode 100644 backend/controllers/login_controller.go diff --git a/backend/controllers/login_controller.go b/backend/controllers/login_controller.go new file mode 100644 index 0000000..996484b --- /dev/null +++ b/backend/controllers/login_controller.go @@ -0,0 +1,21 @@ +package controllers + +import ( + "github.com/gin-gonic/gin" +) + +// LoginController is a struct to define the login controller +type LoginController struct { +} + +// NewLoginController is a function to create a new login controller +func NewLoginController() *LoginController { + return &LoginController{} +} + +// Login is a function to handle the login request +func (controller *LoginController) Login(c *gin.Context) { + c.JSON(200, gin.H{ + "message": "Login", + }) +} \ No newline at end of file diff --git a/backend/routes/router.go b/backend/routes/router.go index da3c777..d495995 100644 --- a/backend/routes/router.go +++ b/backend/routes/router.go @@ -12,13 +12,13 @@ func GetRouter() *gin.Engine { { users := api.Group("/users") { + loginController := controllers.NewLoginController() + users.POST("/login", loginController.Login) } - friends := api.Group("/friends") - { - } - } - + // friends := api.Group("/friends") + // { + // } } return router From db43a3fc7171156fad2180e4efda26e714c99676 Mon Sep 17 00:00:00 2001 From: oginoshikibu Date: Sat, 7 Sep 2024 15:45:54 +0900 Subject: [PATCH 06/14] Add FriendsController and route for getting friends --- backend/controllers/friends_controller.go | 22 ++++++++++++++++++++++ backend/routes/router.go | 8 +++++--- 2 files changed, 27 insertions(+), 3 deletions(-) create mode 100644 backend/controllers/friends_controller.go diff --git a/backend/controllers/friends_controller.go b/backend/controllers/friends_controller.go new file mode 100644 index 0000000..a49ec67 --- /dev/null +++ b/backend/controllers/friends_controller.go @@ -0,0 +1,22 @@ +package controllers + +import ( + "github.com/gin-gonic/gin" +) + +// FriendsController is a struct to define the friends controller +type FriendsController struct { +} + +// NewFriendsController is a function to create a new friends controller +func NewFriendsController() *FriendsController { + return &FriendsController{} +} + + +// GetFriends is a function to handle the get friends request +func (controller *FriendsController) GetFriends(c *gin.Context) { + c.JSON(200, gin.H{ + "message": "Get Friends", + }) +} diff --git a/backend/routes/router.go b/backend/routes/router.go index d495995..f611646 100644 --- a/backend/routes/router.go +++ b/backend/routes/router.go @@ -16,9 +16,11 @@ func GetRouter() *gin.Engine { users.POST("/login", loginController.Login) } - // friends := api.Group("/friends") - // { - // } + friends := api.Group("/friends") + { + friendsController := controllers.NewFriendsController() + friends.GET("/", friendsController.GetFriends) + } } return router From cc4dffe3ba0ec4816d809d17531a54316a8ab7b6 Mon Sep 17 00:00:00 2001 From: oginoshikibu Date: Sat, 7 Sep 2024 16:13:45 +0900 Subject: [PATCH 07/14] Add database package and models for User and Friend --- backend/models/database/database.go | 10 ++++++++++ backend/models/friend.go | 11 +++++++++++ backend/models/user.go | 10 ++++++++++ 3 files changed, 31 insertions(+) create mode 100644 backend/models/database/database.go create mode 100644 backend/models/friend.go create mode 100644 backend/models/user.go diff --git a/backend/models/database/database.go b/backend/models/database/database.go new file mode 100644 index 0000000..11d317a --- /dev/null +++ b/backend/models/database/database.go @@ -0,0 +1,10 @@ +package database + +import ( + "github.com/jinzhu/gorm" +) + +// Database struct +type Database struct { + *gorm.DB +} diff --git a/backend/models/friend.go b/backend/models/friend.go new file mode 100644 index 0000000..5db4e90 --- /dev/null +++ b/backend/models/friend.go @@ -0,0 +1,11 @@ +package models + +import ( + "github.com/jinzhu/gorm" +) + +// Friend struct +type Friend struct { + gorm.Model +} + diff --git a/backend/models/user.go b/backend/models/user.go new file mode 100644 index 0000000..e6f4095 --- /dev/null +++ b/backend/models/user.go @@ -0,0 +1,10 @@ +package models + +import ( + "github.com/jinzhu/gorm" +) + +// User struct +type User struct { + gorm.Model +} \ No newline at end of file From 372c5133c9228face15e9c5c7ce40d6d7e8d922b Mon Sep 17 00:00:00 2001 From: oginoshikibu Date: Sat, 7 Sep 2024 17:10:57 +0900 Subject: [PATCH 08/14] Add request/response structs for GetFriends and Login --- backend/controllers/friends_controller.go | 14 ++++++++++--- backend/controllers/login_controller.go | 24 ++++++++++++++++++++--- 2 files changed, 32 insertions(+), 6 deletions(-) diff --git a/backend/controllers/friends_controller.go b/backend/controllers/friends_controller.go index a49ec67..fc2a0e4 100644 --- a/backend/controllers/friends_controller.go +++ b/backend/controllers/friends_controller.go @@ -2,6 +2,7 @@ package controllers import ( "github.com/gin-gonic/gin" + "net/http" ) // FriendsController is a struct to define the friends controller @@ -14,9 +15,16 @@ func NewFriendsController() *FriendsController { } +// GetFriendsResponse is a struct to define the get friends response +type GetFriendsResponse struct { + Message string `json:"message"` +} + // GetFriends is a function to handle the get friends request func (controller *FriendsController) GetFriends(c *gin.Context) { - c.JSON(200, gin.H{ - "message": "Get Friends", - }) + + var response GetFriendsResponse + response.Message = "Get friends successful" + c.JSON(http.StatusOK, response) + return } diff --git a/backend/controllers/login_controller.go b/backend/controllers/login_controller.go index 996484b..733d709 100644 --- a/backend/controllers/login_controller.go +++ b/backend/controllers/login_controller.go @@ -2,6 +2,7 @@ package controllers import ( "github.com/gin-gonic/gin" + "net/http" ) // LoginController is a struct to define the login controller @@ -13,9 +14,26 @@ func NewLoginController() *LoginController { return &LoginController{} } +// LoginRequest is a struct to define the login request +type LoginRequest struct { + Message string `json:"message" binding:"required"` +} + +// LoginResponse is a struct to define the login response +type LoginResponse struct { + Message string `json:"message"` +} + // Login is a function to handle the login request func (controller *LoginController) Login(c *gin.Context) { - c.JSON(200, gin.H{ - "message": "Login", - }) + var request LoginRequest + if err := c.ShouldBindJSON(&request); err != nil { + c.JSON(http.StatusBadRequest, gin.H{"error": err.Error()}) + return + } + + var response LoginResponse + response.Message = "Login successful" + c.JSON(http.StatusOK, response) + return } \ No newline at end of file From 55643586abf6af53ac11ec0850cb6f778023fa87 Mon Sep 17 00:00:00 2001 From: oginoshikibu Date: Sat, 7 Sep 2024 17:30:56 +0900 Subject: [PATCH 09/14] remove redundant return --- backend/controllers/friends_controller.go | 1 - backend/controllers/login_controller.go | 1 - 2 files changed, 2 deletions(-) diff --git a/backend/controllers/friends_controller.go b/backend/controllers/friends_controller.go index fc2a0e4..fa685c1 100644 --- a/backend/controllers/friends_controller.go +++ b/backend/controllers/friends_controller.go @@ -26,5 +26,4 @@ func (controller *FriendsController) GetFriends(c *gin.Context) { var response GetFriendsResponse response.Message = "Get friends successful" c.JSON(http.StatusOK, response) - return } diff --git a/backend/controllers/login_controller.go b/backend/controllers/login_controller.go index 733d709..8447600 100644 --- a/backend/controllers/login_controller.go +++ b/backend/controllers/login_controller.go @@ -35,5 +35,4 @@ func (controller *LoginController) Login(c *gin.Context) { var response LoginResponse response.Message = "Login successful" c.JSON(http.StatusOK, response) - return } \ No newline at end of file From 272601ed190b0a701e4d80ef001e06f67f5d406c Mon Sep 17 00:00:00 2001 From: oginoshikibu Date: Sat, 7 Sep 2024 17:31:06 +0900 Subject: [PATCH 10/14] Refactor import statements to use gorm.io/gorm package --- backend/models/database/database.go | 2 +- backend/models/friend.go | 2 +- backend/models/user.go | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/backend/models/database/database.go b/backend/models/database/database.go index 11d317a..9ff732a 100644 --- a/backend/models/database/database.go +++ b/backend/models/database/database.go @@ -1,7 +1,7 @@ package database import ( - "github.com/jinzhu/gorm" + "gorm.io/gorm" ) // Database struct diff --git a/backend/models/friend.go b/backend/models/friend.go index 5db4e90..8459720 100644 --- a/backend/models/friend.go +++ b/backend/models/friend.go @@ -1,7 +1,7 @@ package models import ( - "github.com/jinzhu/gorm" + "gorm.io/gorm" ) // Friend struct diff --git a/backend/models/user.go b/backend/models/user.go index e6f4095..a40a8ca 100644 --- a/backend/models/user.go +++ b/backend/models/user.go @@ -1,7 +1,7 @@ package models import ( - "github.com/jinzhu/gorm" + "gorm.io/gorm" ) // User struct From 3b152b92c3fbe73e4e31039c0d94468caa736425 Mon Sep 17 00:00:00 2001 From: oginoshikibu Date: Thu, 12 Sep 2024 12:25:27 +0900 Subject: [PATCH 11/14] write docs --- docs/02.Backend/00.DirStructure/README.md | 32 +++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/docs/02.Backend/00.DirStructure/README.md b/docs/02.Backend/00.DirStructure/README.md index 151b177..4a479b1 100644 --- a/docs/02.Backend/00.DirStructure/README.md +++ b/docs/02.Backend/00.DirStructure/README.md @@ -1 +1,33 @@ # 00.DirStructure + +バックエンドのディレクトリ構造は以下のようになっている。 + +```bash +backend/ +├── Dockerfile +├── README.md +├── controllers +├── go.mod +├── go.sum +├── main.go +├── middleware +├── models +│ └── database +└── routes +``` + +1. **Dockerfile**: バックエンドイメージをビルドするためのDockerfile +2. **README.md**: このファイル +3. **controllers**: バックエンドのコントローラー +4. **go.mod**: Goモジュールファイル +5. **go.sum**: Goのサムファイル +6. **main.go**: バックエンドのエントリーポイント +7. **middleware**: バックエンドのミドルウェア +8. **models**: バックエンドのモデル + - **database**: +9. **routes**: バックエンドのルート +10. **tmp**: Airによって作成されたバックエンドの一時ディレクトリ + + +基本的にMVC(Model-View-Controller)パターンに従ってディレクトリ構造を設計している。 +現状バックエンドは単にAPIサーバーとしての機能しか持たない予定のため、Viewは存在しない。 From cfad2dc48007e38bd90e4c263c81b24c19ee3da6 Mon Sep 17 00:00:00 2001 From: oginoshikibu Date: Thu, 12 Sep 2024 12:27:33 +0900 Subject: [PATCH 12/14] =?UTF-8?q?middleware=E3=81=8C=E5=AD=98=E5=9C=A8?= =?UTF-8?q?=E3=81=97=E3=81=AA=E3=81=84=E3=81=93=E3=81=A8=E3=81=AB=E3=81=A4?= =?UTF-8?q?=E3=81=84=E3=81=A6=E8=A8=80=E5=8F=8A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- backend/controllers/login_controller_test.go | 102 +++++++++++++++++++ docs/02.Backend/00.DirStructure/README.md | 4 +- 2 files changed, 104 insertions(+), 2 deletions(-) create mode 100644 backend/controllers/login_controller_test.go diff --git a/backend/controllers/login_controller_test.go b/backend/controllers/login_controller_test.go new file mode 100644 index 0000000..aa684fe --- /dev/null +++ b/backend/controllers/login_controller_test.go @@ -0,0 +1,102 @@ +package controllers + +import ( + "encoding/json" + "github.com/gin-gonic/gin" + "net/http" + "net/http/httptest" + "strings" + "testing" +) + +type testRequestBody struct { + Message any `json:"message"` +} + +type preferResponse struct { + code int + body map[string]interface{} +} + +func TestLoginController_Login(t *testing.T) { + + tests := []struct { + name string + request testRequestBody + want preferResponse + }{ + { + name: "Test case 1: Success", + request: testRequestBody{ + Message: "Hello", + }, + want: preferResponse{ + code: http.StatusOK, + body: map[string]interface{}{ + "message": "Login successful", + }, + }, + }, + { + name: "Test case 2: Failed with empty", + request: testRequestBody{}, + want: preferResponse{ + code: http.StatusBadRequest, + body: map[string]interface{}{ + "error": "Key: 'LoginRequest.Message' Error:Field validation for 'Message' failed on the 'required' tag", + }, + }, + }, + { + name: "Test case 3: Failed with number", + request: testRequestBody{ + Message: 123, + }, + want: preferResponse{ + code: http.StatusBadRequest, + body: map[string]interface{}{ + "error": "json: cannot unmarshal number into Go struct field LoginRequest.message of type string", + }, + }, + }, + } + + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + response := httptest.NewRecorder() + c, _ := gin.CreateTestContext(response) + + requestBody, _ := json.Marshal(tt.request) + c.Request, _ = http.NewRequest( + http.MethodPost, + "api/v1/users/login", + strings.NewReader(string(requestBody)), + ) + + c.Request.Header.Set("Content-Type", "application/json") + + NewLoginController().Login(c) + + if response.Code != tt.want.code { + t.Errorf("Login() got = %v, want %v", response.Code, tt.want.code) + } else { + var body map[string]interface{} + var err = json.Unmarshal(response.Body.Bytes(), &body) + if err != nil { + t.Errorf("Login() got = %v, want %v", response.Body, tt.want.body) + } + + // to compare + for key := range tt.want.body { + if _, exist := body[key]; exist { + if body[key] != tt.want.body[key] { + t.Errorf("Login() got = %v, want %v", response.Body, tt.want.body) + } + } else { + t.Errorf("Login() got = %v, want %v", response.Body, tt.want.body) + } + } + } + }) + } +} diff --git a/docs/02.Backend/00.DirStructure/README.md b/docs/02.Backend/00.DirStructure/README.md index 4a479b1..ca5688d 100644 --- a/docs/02.Backend/00.DirStructure/README.md +++ b/docs/02.Backend/00.DirStructure/README.md @@ -22,10 +22,10 @@ backend/ 4. **go.mod**: Goモジュールファイル 5. **go.sum**: Goのサムファイル 6. **main.go**: バックエンドのエントリーポイント -7. **middleware**: バックエンドのミドルウェア +7. **middleware**: バックエンドのミドルウェア(現状空の為、git未追跡) 8. **models**: バックエンドのモデル - **database**: -9. **routes**: バックエンドのルート +9. **routes**: バックエンドのルート 10. **tmp**: Airによって作成されたバックエンドの一時ディレクトリ From ca814bc7eb5dbc2199afc4ea7707b618a5767029 Mon Sep 17 00:00:00 2001 From: oginoshikibu Date: Thu, 12 Sep 2024 12:31:16 +0900 Subject: [PATCH 13/14] =?UTF-8?q?=E8=AA=A4=E3=81=A3=E3=81=A6commit?= =?UTF-8?q?=E3=81=97=E3=81=9F=E3=83=95=E3=82=A1=E3=82=A4=E3=83=AB=E3=81=AE?= =?UTF-8?q?=E5=89=8A=E9=99=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- backend/controllers/login_controller_test.go | 102 ------------------- 1 file changed, 102 deletions(-) delete mode 100644 backend/controllers/login_controller_test.go diff --git a/backend/controllers/login_controller_test.go b/backend/controllers/login_controller_test.go deleted file mode 100644 index aa684fe..0000000 --- a/backend/controllers/login_controller_test.go +++ /dev/null @@ -1,102 +0,0 @@ -package controllers - -import ( - "encoding/json" - "github.com/gin-gonic/gin" - "net/http" - "net/http/httptest" - "strings" - "testing" -) - -type testRequestBody struct { - Message any `json:"message"` -} - -type preferResponse struct { - code int - body map[string]interface{} -} - -func TestLoginController_Login(t *testing.T) { - - tests := []struct { - name string - request testRequestBody - want preferResponse - }{ - { - name: "Test case 1: Success", - request: testRequestBody{ - Message: "Hello", - }, - want: preferResponse{ - code: http.StatusOK, - body: map[string]interface{}{ - "message": "Login successful", - }, - }, - }, - { - name: "Test case 2: Failed with empty", - request: testRequestBody{}, - want: preferResponse{ - code: http.StatusBadRequest, - body: map[string]interface{}{ - "error": "Key: 'LoginRequest.Message' Error:Field validation for 'Message' failed on the 'required' tag", - }, - }, - }, - { - name: "Test case 3: Failed with number", - request: testRequestBody{ - Message: 123, - }, - want: preferResponse{ - code: http.StatusBadRequest, - body: map[string]interface{}{ - "error": "json: cannot unmarshal number into Go struct field LoginRequest.message of type string", - }, - }, - }, - } - - for _, tt := range tests { - t.Run(tt.name, func(t *testing.T) { - response := httptest.NewRecorder() - c, _ := gin.CreateTestContext(response) - - requestBody, _ := json.Marshal(tt.request) - c.Request, _ = http.NewRequest( - http.MethodPost, - "api/v1/users/login", - strings.NewReader(string(requestBody)), - ) - - c.Request.Header.Set("Content-Type", "application/json") - - NewLoginController().Login(c) - - if response.Code != tt.want.code { - t.Errorf("Login() got = %v, want %v", response.Code, tt.want.code) - } else { - var body map[string]interface{} - var err = json.Unmarshal(response.Body.Bytes(), &body) - if err != nil { - t.Errorf("Login() got = %v, want %v", response.Body, tt.want.body) - } - - // to compare - for key := range tt.want.body { - if _, exist := body[key]; exist { - if body[key] != tt.want.body[key] { - t.Errorf("Login() got = %v, want %v", response.Body, tt.want.body) - } - } else { - t.Errorf("Login() got = %v, want %v", response.Body, tt.want.body) - } - } - } - }) - } -} From aaa88175503210ec53a32faf20425fac11070252 Mon Sep 17 00:00:00 2001 From: oginoshikibu Date: Thu, 12 Sep 2024 12:50:51 +0900 Subject: [PATCH 14/14] =?UTF-8?q?MVC=E3=81=AB=E3=81=97=E3=81=9F=E8=83=8C?= =?UTF-8?q?=E6=99=AF=E3=81=AB=E3=81=A4=E3=81=84=E3=81=A6=E3=80=81=E4=B8=80?= =?UTF-8?q?=E6=96=87=E8=BF=BD=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/02.Backend/00.DirStructure/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/02.Backend/00.DirStructure/README.md b/docs/02.Backend/00.DirStructure/README.md index ca5688d..ed63b9f 100644 --- a/docs/02.Backend/00.DirStructure/README.md +++ b/docs/02.Backend/00.DirStructure/README.md @@ -30,4 +30,5 @@ backend/ 基本的にMVC(Model-View-Controller)パターンに従ってディレクトリ構造を設計している。 +開発者のレベルを考慮し、分かりやすいアーキテクチャを選択した。 現状バックエンドは単にAPIサーバーとしての機能しか持たない予定のため、Viewは存在しない。