Document URL pattern best practices#11227
Conversation
0c5affb to
e45c3d3
Compare
|
@WimJongeneel Please let us know when this is ready for tech writers' review. Thanks! |
| When designing page and microflow URLs, prefer clear path segments over compact patterns: | ||
|
|
||
| * Use `/` to divide the URL into meaningful parts | ||
| * Prefer putting a parameter in its own segment, for example, `product/{Product/Name}` instead of `product-{Product/Name}` |
There was a problem hiding this comment.
I would state this more explicitly like the recommendation below:
'Put a parameter in its own segment'
|
|
||
| When designing page and microflow URLs, prefer clear path segments over compact patterns: | ||
|
|
||
| * Use `/` to divide the URL into meaningful parts |
There was a problem hiding this comment.
As we are using segments everywhere else, I would say
'into meaningful segments'
| * Use `/` to divide the URL into meaningful parts | ||
| * Prefer putting a parameter in its own segment, for example, `product/{Product/Name}` instead of `product-{Product/Name}` | ||
| * Use static segments to make the structure explicit, for example, `category/{Category/Code}/product/{Product/Name}` | ||
|
|
There was a problem hiding this comment.
Maybe we can add an explicit case to no put a variable as the first segment:
'user/{User/id}instead of{User/id}`
| URL conflicts are checked per path segment. Two URLs are considered conflicting when they have the same number of segments and Studio Pro cannot determine that at least one corresponding segment is always different. | ||
|
|
||
| Common conflict cases include the following: | ||
|
|
There was a problem hiding this comment.
I think we should distinguish here between full and partially conflicting URLs
There was a problem hiding this comment.
And moreover, describe what happens when there is a partially conflicting URL. (with a concrete example)
| URL conflicts are checked per path segment. Two URLs are considered conflicting when they have the same number of segments and Studio Pro cannot determine that at least one corresponding segment is always different. | ||
|
|
||
| Common conflict cases include the following: | ||
|
|
There was a problem hiding this comment.
I think it would be helpful to show how these conflicts can resolved. For example for
product/{Product/Name} and product/{Product/Code}
we can use more explicit URLs like:
product/name/{Product/Name} and product/code/{Product/Code}
For order/{Order/Id} and order/123
we can do
order/{Order/Id} and order-123
etc
| * Use `/` to divide the URL into meaningful parts | ||
| * Prefer putting a parameter in its own segment, for example, `product/{Product/Name}` instead of `product-{Product/Name}` | ||
| * Use static segments to make the structure explicit, for example, `category/{Category/Code}/product/{Product/Name}` | ||
|
|
There was a problem hiding this comment.
We could say to use - for seperating static segment descriptions, for example:
/orders/request-return-label
Add some guidance on structuring URLs within a Mendix App