retype icon indicating copy to clipboard operation
retype copied to clipboard

Title override for main page

Open geoffreymcgill opened this issue 2 years ago • 2 comments

Discussed in https://github.com/retypeapp/retype/discussions/346

Originally posted by DannyBen June 26, 2022 I am looking for an ability to completely override the title of the main page, for search engine visibility purposes.

Right now, the main page is handled like any other page, and receiving the title suffix as defined in the config's meta.title:

meta:
  title: " | Bashly - Bash CLI Framework"

I was looking at retype's title page configuration, but it is obviously not intended for this.

Can this be done? If not, can this be considered as a feature?

Ideally, I think this should be definable at the page level:

# page front matter
title_override: "My search-engine-friendly title"  # which will appear without the global suffix
---
```</div>

geoffreymcgill avatar Jun 29 '22 04:06 geoffreymcgill

Hi @DannyBen. Good question and an interesting scenario. Maybe a matching meta.title config in the page metadata would be a good option.

meta:
  title: "Custom meta tag title here which overrides generated meta tag title"

Where setting meta.title completely overrides the default functionality of the generated <title> value. Whatever you set at the page config level would be the exact value set in the <title> meta tag for that generated page.

Let me know if you like the meta.title config name. This config option would be easy for us to add.

geoffreymcgill avatar Jun 29 '22 04:06 geoffreymcgill

Yes, sounds perfectly logical and intuitive.

I am guessing the current title in the page-level config still needs to stay and retain its current meaning?

DannyBen avatar Jun 29 '22 05:06 DannyBen

This feature has been implemented and will be available in the upcoming Retype v3.0 release.

geoffreymcgill avatar Mar 15 '23 20:03 geoffreymcgill