app/profile/[name]/page.js
The [name]
signifies a wildcard, that can be filled in by another request.
Wildcard Routes
Theses are directories
[anything]/
Translates to:
example.com/{anything}
Grabbing Route ID
If you named the route folder as [id]/
export default function GetID({ params }){
return (
<div> {params.id} </div>
)
}
Ignored Routes
(group)/
It will be ignored by the url routing. Good if you want to put a file and not have it affect the URL structure.