Skip to content

Commit

Permalink
Reorder route related commandment
Browse files Browse the repository at this point in the history
There is a dedicated section on Routes...
  • Loading branch information
tmaier authored and purinkle committed May 22, 2022
1 parent 4cbcfdc commit 4ee4db0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion rails/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
# Rails

- Avoid `member` and `collection` routes.
- Use private instead of protected when defining controller methods.
- Name date columns with `_on` suffixes.
- Name datetime columns with `_at` suffixes.
Expand Down Expand Up @@ -81,6 +80,7 @@
## Routes

- Avoid the `:except` option in routes.
- Avoid `member` and `collection` routes.
- Order resourceful routes alphabetically by name.
- Use the `:only` option to explicitly state exposed routes.
- Prefer [resource routing] over [generating routes] individually
Expand Down

0 comments on commit 4ee4db0

Please sign in to comment.