Devs.tw 是讓工程師寫筆記、網誌的平台。歡迎您隨手紀錄、寫作,方便日後搜尋!
todo
https://www.facebook.com/groups
https://www.facebook.com/groups/remotetaiwan/
https://www.facebook.com/pages
https://www.facebook.com/messages/t/
https://www.facebook.com/events/
https://www.facebook.com/events/2064662180513132/
https://www.reddit.com/r/PHP/comments/9v1gil/php2go/
google.com/analytics
google.com/analytics/settings
google.com/analytics/feeds
google.com/books
google.com/catalogs
google.com/maps
google.com/places
google.com/trends
bing.com/images
bing.com/maps
bing.com/results
bing.com/videos
stackoverflow.com/users/
stackoverflow.com/feeds/
stackoverflow.com/questions/
stackoverflow.com/tags/
stackoverflow.com/help/badges
https://www.reddit.com/r/PHP/comments/9v1gil/php2go/
https://www.reddit.com/user/howtomakeaturn
refs:
https://serverfault.com/questions/73682/standard-for-singular-vs-plural-type-names-in-urls
原來如此
不過我找到一篇說的也不錯 他是連單一資源也一併用複數 讓網址類似資料夾路徑結構
用戶可以在 url 內刪掉最後一個單字回到上一層 我上網時 有時的確也會這麼做
My preferred approach is face a website like a directories structure. This gives more semantic, and makes easier to power users to predict listing directories.
In your case:
www.mysite.com/ #root
www.mysite.com/stores/ #stores listing
www.mysite.com/stores/paris #paris store details
Note the predictable structure. Trailing slash let people and crawlers understand that it threats about a directory root.
Power users that land in paris store for example, can be tempted to just delete "paris" from URL and expect to see the parent list or something like that (they tend to face URLs as breadcrumbs). This is why I think this approach is the more interesting.
印象中 RESTful API 設計的建議是一般用複數
但是在對使用者來說是單一資源的時候,則用單數
比如使用者自己的資訊用 /user,但自己相簿裡的照片用 /images
這就可以解釋為什麼你 Reddit 的例子是混合的了