Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add titleSuffix as future replacement for header.organisationName option #298

Merged
merged 5 commits into from
Jul 23, 2024

Conversation

frankieroberto
Copy link
Contributor

@frankieroberto frankieroberto commented Jul 23, 2024

This moves the organisationName config option out from the header config option to be a top-level config option named titleSuffi, as it is now only used in the title tag.

To avoid a breaking change, header.organisationName is still supported a fallback. This could be removed in a future breaking change release.

Additionally, if both titleSuffix and header.organisationName are set to false, then the - will not be added to the title tag (for scenarios where an title suffix might not be needed).

@frankieroberto
Copy link
Contributor Author

As well as moving this option, it could be renamed to something like titleSuffix, which might make it a bit clearer what it does? (Also I guess strictly speaking GOV.UK isn't an organisation).

@paulrobertlloyd
Copy link
Collaborator

I think titleSuffix makes sense.

Do we need to keep header.organisationName given that, in theory, this value is no longer supported in v6?

@frankieroberto
Copy link
Contributor Author

I think titleSuffix makes sense.

Do we need to keep header.organisationName given that, in theory, this value is no longer supported in v6?

If we remove it and anyone has set a custom suffix, then it’ll revert back to - GOV.UK, which feels like a kinda breaking change? Although maybe it’s low risk and we could do a search to see if this affects anyone?

@frankieroberto
Copy link
Contributor Author

I've renamed to titleSuffix but kept the backwards-compatibility for now. But feel free to remove that if you don’t think it’ll affect anyone significantly.

@frankieroberto frankieroberto changed the title Move organisationName config Rename organisationName as titleSuffix Jul 23, 2024
@paulrobertlloyd
Copy link
Collaborator

paulrobertlloyd commented Jul 23, 2024

Maybe we keep the backwards compatibility for now, and remove in v7. We can add an issue and assign it to the v7.0 milestone. I’m expecting that to have a number of breaking changes, given it will change how layouts are loaded from the plugin (and likely see a move to ES module syntax, too).

frankieroberto and others added 5 commits July 23, 2024 19:21
Moves the organisationName config option out from the `header` config option to be a top-level config option.

This is now only used in the title tag.
@paulrobertlloyd paulrobertlloyd force-pushed the move-organisation-name-config branch from 7fe2c40 to 5f783c0 Compare July 23, 2024 18:22
@paulrobertlloyd paulrobertlloyd changed the title Rename organisationName as titleSuffix Add titleSuffix as future replacement for header.organisationName option Jul 23, 2024
@paulrobertlloyd paulrobertlloyd merged commit 50224c3 into main Jul 23, 2024
2 checks passed
@paulrobertlloyd paulrobertlloyd deleted the move-organisation-name-config branch July 23, 2024 18:26
paulrobertlloyd added a commit that referenced this pull request Jul 23, 2024
… option (#298)

Adds `titleSuffix` option to replace the undocumented `header.organisationName` option as this value is now only used in the document title.

---------

Co-authored-by: Paul Robert Lloyd <me+git@paulrobertlloyd.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants