Skip to content

Add open-graph tags support - #31

Open
jchapuis wants to merge 4 commits into
sbt:mainfrom
jchapuis:add-open-graph-tags
Open

Add open-graph tags support#31
jchapuis wants to merge 4 commits into
sbt:mainfrom
jchapuis:add-open-graph-tags

Conversation

@jchapuis

Copy link
Copy Markdown

No description provided.

@mkurz

mkurz commented Feb 13, 2024

Copy link
Copy Markdown
Member

@jchapuis Can you please rebase to solve conflicts? Thanks!

@jchapuis
jchapuis force-pushed the add-open-graph-tags branch from f18986d to b30f8e2 Compare February 14, 2024 15:17
@jchapuis

Copy link
Copy Markdown
Author

@mkurz sure! done

@jchapuis
jchapuis force-pushed the add-open-graph-tags branch from b30f8e2 to c0bb47d Compare February 14, 2024 15:18
@jchapuis
jchapuis force-pushed the add-open-graph-tags branch from c0bb47d to fc5fb68 Compare February 14, 2024 15:19
@mdedetrich

Copy link
Copy Markdown
Contributor

@jchapuis You need to format the codebase

@jchapuis

Copy link
Copy Markdown
Author

@jchapuis You need to format the codebase

yes i saw it was build.sbt i believe, pushed a commit

@mdedetrich mdedetrich left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think one of the URI's need to be updated

Comment thread build.sbt Outdated

@mdedetrich mdedetrich left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm. @mkurz Want to take a look?

Comment thread theme/src/main/assets/page.st Outdated
<meta http-equiv="x-ua-compatible" content="ie=edge">
<meta name="description" content="$page.properties.("project.description")$">
$ if (page.properties.("project.name")) $
<meta property="og:title" content="$page.properties.("project.name")$">

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if we should use project name as og:title.
Shouldn't we use something like here instead?

$ if (page.properties.("title")) $
<title>$page.properties.("title")$</title>
$ elseif (page.title) $
<title>$page.title$$ if (!page.home.active) $ · $page.home.title$$ endif $</title>
$ else $
<title>$page.home.title$</title>
$ endif $

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think those were metadata of open graph

@mkurz mkurz Feb 27, 2024

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Roiocam I understand that, however my point is if it makes sense to use the "project name" as og:title. Maybe it would be better to use the same value like we use for the html <title> tag.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Got it, makes sense. Thanks

@jchapuis jchapuis Feb 27, 2024

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good point, changed, but i kept the condition logic simple, where you have to define the page title property for it to be exposed in opengraph. Or would we want to have the same logic? trying to avoid unnecessary duplication

@Roiocam Roiocam left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, Thanks @jchapuis. It would be great to get reviews from others.

Comment thread theme/src/main/assets/page.st Outdated
<meta http-equiv="x-ua-compatible" content="ie=edge">
<meta name="description" content="$page.properties.("project.description")$">
$ if (page.properties.("project.name")) $
<meta property="og:title" content="$page.properties.("project.name")$">

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think those were metadata of open graph

@mkurz

mkurz commented Mar 8, 2024

Copy link
Copy Markdown
Member

/cc @mdedetrich maybe you can also take a look here if you have time

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.

4 participants