-
Notifications
You must be signed in to change notification settings - Fork 511
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
Docs: explain index files for server routing #2415
Comments
PR more than welcome to improve nitro docs 🙏🏼 |
Awesome I wanted to wait for feedback from the team before starting working on it. I'll land a PR! |
@geromegrignon please a PR would be huge for this! Using your example, I had my routes configured like this:
It drove me crazy because I couldn't find any examples of doing this any other way while having a feeling it was possible and I was missing something. I only found this because my OCD finally had enough and I decided to spend an hour going through nearly every issue until I came across this. |
Hi @ilyafish, sure I'll work on it tomorrow! Glad it already helped! |
Describe the feature
The server routes documentation is missing a basic folder structure scenario, implying you are familiar with file-based routing structure.
It doesn't explain you can prefix files with
index
, likeindex.get.ts
.It unlocks using a folder for crud operations like:
Or being able to cover routes like
/articles
and/articles/upcoming
.Additional information
The text was updated successfully, but these errors were encountered: