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

Underscores & Hyphens in the og:locale meta tag #462

Closed
2 of 4 tasks
carpiediem opened this issue Aug 18, 2016 · 1 comment
Closed
2 of 4 tasks

Underscores & Hyphens in the og:locale meta tag #462

carpiediem opened this issue Aug 18, 2016 · 1 comment

Comments

@carpiediem
Copy link
Contributor

carpiediem commented Aug 18, 2016

  • This is a question about using the theme.
  • I believe this to be a bug with the theme --- not Jekyll, GitHub Pages or one of the bundled plugins.
  • This is a feature request.
  • [x ] I have updated all gems with bundle update.
  • I have tested locally with bundle exec jekyll build.

Environment informations

Running on github.io


Expected behavior

og:locale meta tag should be processed

Steps to reproduce the behavior

If you test a page in https://developers.facebook.com/tools/debug/sharing/, it shows that the og:locale tag is being rejected. Facebook is expecting a value with an underscore (e.g. "en_US") but the default configuration of minimal-mistakes uses a hyphen (e.g. "en-US").

Simply modifying the _config.yml file isn't an option, since ui-text.yml is written for hyphens. I think those are the only two files that would need to be edited, though.

@mmistakes
Copy link
Owner

Should be an easy fix adding a replace filter and changing the default to en_US to this line in _includes/seo.html

<meta property="og:locale" content="{{ site.locale | replace: "-", "_" | default: "en_US" }}">

koyumi0601 pushed a commit to koyumi0601/koyumi0601.github.io that referenced this issue Jul 31, 2023
This PR combines (and resolves conflicts between) mmistakes#448, mmistakes#463, mmistakes#466, mmistakes#494, mmistakes#495, mmistakes#496, mmistakes#498, and mmistakes#572. 

The main aim is to facilitate use of several of the implemented features _together_, when using the fork as a remote theme. It should also simplify merging the included PRs into a future release.

The branch [combination-rec-nav](https://github.com/pdmosses/just-the-docs/tree/combination-rec-nav) adds [multi-level navigation](just-the-docs/just-the-docs#462) and (NEW:) [sibling links](just-the-docs/just-the-docs#394) to the branch used for this PR. It includes updated [documentation for the navigation structure](https://pdmosses.github.io/just-the-docs/docs/navigation-structure/), and reorganised and extended [navigation tests](https://pdmosses.github.io/just-the-docs/tests/navigation/). The documentation and the tests can be browsed at the (temporary) [website published from the combination-rec-nav branch](https://pdmosses.github.io/just-the-docs/).

_Caveat:_ The changes to v0.3.3 in this PR and mmistakes#462 have not yet been reviewed or approved, and may need updating before merging into a release of the theme. If you use a branch from a PR as a remote theme, there is a risk of such updates affecting your website. Moreover, these branches are likely to be deleted after they have been merged. To avoid  such problems, you could copy the branch that you want to use to your own fork of the theme.

Co-authored-by: Matt Wang <matt@matthewwang.me>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants