Overview
Allow users to set a blog customization option that has posts live on a sub-path (e.g. /posts/) instead of at the top level of the blog.
Background
Primarily for #fight_back_news. Wider community feedback in this forum topic.
Implementation
- Add a collection route: "/posts/{slug}" that shows the post.
- Recognize a new collection attribute: posts_path. If there's any value set, posts live on the sub-path (for now, set to posts)
- If posts live on the sub-path:
- Correctly set the posts' canonical URL
- Link there from the templates: collection.html, collection-tags.html
- Send user there after publishing post in the web app (TODO: see if the WriteFreely SwiftUI app has correct behavior, or update)
- (Note: clients may need to start relying on the published post's url value returned from the API)
- After moving a post to a collection in the web app, send to correct URL
- Continue showing standard blog post list on the "/" route
- On the "/{slug}" route, redirect non-pinned posts to sub-path, otherwise maintain current behavior
- Add a collection route: "/posts/" that shows current standard blog post list (if posts live on sub-path)
Future
- Support a configurable sub-path
- Static landing page