fabianmichael / kirby-meta

All-in-one solution to all of your SEO/OpenGraph/JSON-LD needs. 👀
MIT License
65 stars 8 forks source link

Unlisted pages: Meta-Robots always set to „noindex“ #51

Open FynnZW opened 1 year ago

FynnZW commented 1 year ago

No matter what the page settings are, the HTML tag created is always: <meta name="robots" content="noindex" />

This also seems to affect all children of unlisted pages. I use unlisted for internal reasons, but the page is still public and should be found by robots.

Version: 0.4.0-beta Kirby: 3.9.4

FynnZW commented 1 year ago

I just noticed this is by design. From the readme: robots.index

If a page is excluded from the sitemap or unlisted, the robots meta tag will always contain noindex.

But in my opinion, that is wrong. I like using 'unlisted' for e.g. pages, that are not supposed to show up in a menu, but they are still public and might be important for the organic search. Or just pages that don't need sorting (/example-page instead of /1_example-page, because having a stable folder name can be useful when syncing the content). And it is also confusing to still have those options in the panel/meta-tab, but they don't have any effect.

fabianmichael commented 1 year ago

@FynnZW Hi Fynn, thanks for your feedback. Unfortunately, I had to make a decision at some point and ended-up with excluding unlisted pages mostly because they are labelled "unlisted". I used to rely on Kirby’s sorting numbers in the past for building navigation menus, but nowadays I prefer to use a pages/structure field or similiar to that task. Just using the page status often caused confusion and is not very flexible. Given that fact, that this plugin is already used by more than just a few people, I cannot change the behavior at this point without introducing a major breaking change and a possibel security risk.

You can however use the sitemap.templates.includeUnlisted option to including unlisted pages as a workaround.

FynnZW commented 1 year ago

Sorry for the late reply - that option sounds good! Will it be possible to use this wildcard to include all unlisted?

sitemap.templates.includeUnlisted: [*]

Given that fact, that this plugin is already used by more than just a few people, I cannot change the behavior at this point without introducing a major breaking change and a possibel security risk.

I understand. But I think this should be obvious in the panel, and right now the settings are present and editable, but they have no effect:

Screen 2023-08-22 at 13 38 00

Maybe it's possible to check if the page is unlisted, and then disable these controls? I think it's confusing otherwise.

fabianmichael commented 1 year ago

@FynnZW Unfortunately blueprints are not that dynamic but I can update the help text at least …