Adopt Snake Case Naming for Route Paths and Names #20318
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hey everyone,
I’ve got a quick idea I’d love to share: let’s embrace snake_case for our routing in Symfony and make sure it’s included in the contribution docs.
1. RFC Compliance
First off, the RFC 3986 gives us the thumbs up for clear naming conventions.
snake_case
does just that—it's super readable and fits the bill perfectly.2. Practices of Other Languages
Plus, many languages like Python and Ruby are already on the snake_case train. This makes it way easier for developers coming from other backgrounds.
3. Industry Practices
And hey, check this out: major players like Google, Facebook, and Twitter use snake_case in their APIs. If it’s good enough for them, it’s definitely worth considering!
Conclusion
By adopting
snake_case
for route names and paths and adding this to our contribution docs, we’ll boost the consistency and clarity of Symfony.