-
Notifications
You must be signed in to change notification settings - Fork 33
Add open-graph tags support #31
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
base: main
Are you sure you want to change the base?
Changes from 2 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
@@ -27,6 +27,15 @@ $! | |||||||||||||||
<meta name="viewport" content="width=device-width,initial-scale=1"> | ||||||||||||||||
<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")$"> | ||||||||||||||||
|
$ 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 $ |
There was a problem hiding this comment.
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
There was a problem hiding this comment.
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.
There was a problem hiding this comment.
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
There was a problem hiding this comment.
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
Uh oh!
There was an error while loading. Please reload this page.