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

Used open graph protocol to add site meta data #53

Merged
merged 4 commits into from
Nov 30, 2024

Conversation

SirChronicle
Copy link
Contributor

@SirChronicle SirChronicle commented Nov 23, 2024

Fixes #28

parameters used:

title: "Null NEU"
description: "A cybersecurity club at Northeastern University focused on learning and sharing knowledge in security."

Copy link
Member

@Parthiv-M Parthiv-M left a comment

Choose a reason for hiding this comment

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

The approach is spot on, just some more improvements!

  • Would be helpful if we can add the following tags

    <meta name="description" content="{{ if .Description }}{{ .Description }}{{ else }}{{ .Site.Params.description }}{{ end }}" />
    
    <meta name="twitter:title" content="{{ .Title }} | {{ .Site.Title }}" />
    <meta name="twitter:image" content="{{ .Site.Params.og_image | absURL }}" />
    
    <meta itemprop="name" content="{{ .Title }} | {{ .Site.Title }}" />
    <meta name="application-name" content="{{ .Title }} | {{ .Site.Title }}" />
    
    <meta property="og:title" content="{{ .Title }} | {{ .Site.Title }}" />
    <meta property="og:type" content="website" />
    <meta property="og:title" content="{{ .Site.Title }}" />
    <meta property="og:description"content="{{ if .Description }}{{ .Description }}{{ else }}{{ .Site.Params.description }}{{ end }}" />
    <meta property="og:site_name" content="{{ .Site.Title }}" />
    <meta property="og:url" content="{{ .Permalink }}" />
    <meta property="og:locale" content="en">
    <meta property="og:image" content="{{ .Params.Site.BaseURL }}{{ .Site.Params.og_image | relURL }}" />
    <meta property="og:image:secure_url" content="{{ .Site.Params.og_image | absURL }}" />
    <meta property="og:type" content="website" />
    

    This is just something I got off another resource, please validate and modify accordingly before including in our partial.

layouts/partials/opengraph.html Outdated Show resolved Hide resolved
layouts/partials/opengraph.html Outdated Show resolved Hide resolved
simplified meta tags and added new ones
@SirChronicle
Copy link
Contributor Author

I've added the suggested meta tags after reviewing each (commented all tags for images for future updates) and updated the relevant files. Let me know if there's anything else to adjust!

@Parthiv-M Parthiv-M merged commit 5f70173 into nullNEU:main Nov 30, 2024
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.

Use Open Graph protocol to add site meta data
2 participants