-
-
Notifications
You must be signed in to change notification settings - Fork 52
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add better naming for api controller methods #391
Conversation
reference: Phoenix Framework ``` user_path GET /users HelloWeb.UserController :index user_path GET /users/:id/edit HelloWeb.UserController :edit user_path GET /users/new HelloWeb.UserController :new user_path GET /users/:id HelloWeb.UserController :show user_path POST /users HelloWeb.UserController :create user_path PATCH /users/:id HelloWeb.UserController :update PUT /users/:id HelloWeb.UserController :update user_path DELETE /users/:id HelloWeb.UserController :delete ``` Rails: ``` GET /photos photos#index display a list of all photos GET /photos/new photos#new return an HTML form for creating a new photo POST /photos photos#create create a new photo GET /photos/:id photos#show display a specific photo GET /photos/:id/edit photos#edit return an HTML form for editing a photo PATCH/PUT /photos/:id photos#update update a specific photo DELETE /photos/:id photos#destroy delete a specific photo ```
Maybe different templates could be used to emulate masonite, phoenix and rails ways. |
I keep looking at this PR but what is "better" about these? |
I'm not sure about the better, but the developer coming from MVC based framework background might find it confsuing, We can keep |
🤔 hmm ok I think i'm on board now but I'm not a huge fan of |
Yeah, you are right. They do sound similar and not convey what it does, create I can understand, but yeah, |
I'm gonna close this until we are in more of an agreement on what to call the methods |
sure |
reference:
Phoenix Framework
Rails: