Oh, yes, I’m all for this! @manton and I talked about this over mail back in February. I’m including my initial letter here for a bit of background and my proposal for how this could work.
Hey Manton,
Here are my thoughts spurred by the discussion about pages from plug-ins in the menu. It makes sense to ship pages to the end-user for many plug-ins, like my own Surprise me!, Search page by renowned Manton Reece, and Amit’s Posts Stats.
Generally, people like stuff that “just works”. So I would gladly just tuck the Surprise me! page in the menu for them. Except I don’t, because:
- What if the blog is in another language, and the owner wants to change the page name?
- Or maybe they want to rearrange the order of the menu.
- Some people don’t want that thing in the menu at all.
So instead, I just ship the page, and it’s up to the person installing the plug-in to add the page to the menu if they want. The problem is that’s not intuitive, and one might end up causing infinite redirect.
Maybe it could work like this? For example, plug-in developers adds the following frontmatter to their page:
--- title: "Surprise me!" url: "/surprise-me/" menu: "main" ---
The page automatically shows up in the page list and can be rearranged:
When the user taps on the page, they end up on an almost ordinary edit page:
This edit page differs from an ordinary edit page in a handful of ways:
- The user is informed that this page is special, provided by the Surprise me! plug-in.
- Because of that, the page can’t be deleted.
- It can, however, be hidden from the menu.
- It’s also possible to change the title…
- and the path (technically, that’s the slug in the pages front matter).
- For some plug-ins, it even makes sense to allow additional user content.
So in a way, it’s pretty similar to how special pages like About, Photos, and Replies work today. But sprinkled with more features.