Giter Club home page Giter Club logo

Comments (6)

RichardLitt avatar RichardLitt commented on August 21, 2024

I added these. Happy to put them in a PR?

  <meta property="og:description" content="{% if page.excerpt %}{{ page.excerpt | strip_html | strip_newlines | truncate: 160 }}{% else %}{{ site.description }}{% endif %}" />
  <meta property="og:url" content="{{ site.url }}" />
  <meta property="og:site_name" content="{{ site.title }}" />
  <meta property="og:title" content="{{ site.title }}" />
  <meta property="og:type" content="website" />
  <meta property="og:image" content="{{ "assets/twitter_360.png"| prepend: site.baseurl | prepend: site.url }}" />
  <meta property="og:image:type" content="image/png" />
  <meta property="og:image:width" content="360" />
  <meta property="og:image:height" content="360" />

  <!-- Twitter: card tags -->
  <meta name="twitter:card" content="summary">
  <meta name="twitter:title" content="{{ site.title }}">
  <meta name="twitter:description" content="{% if page.excerpt %}{{ page.excerpt | strip_html | strip_newlines | truncate: 160 }}{% else %}{{ site.description }}{% endif %}">
  <meta name="twitter:image" content="{{ "assets/twitter_360.png" | prepend: site.baseurl | prepend: site.url }}">
  <meta name="twitter:url" content="{{ site.url }}">  

  <!-- Open Source Protocol -->
  <link rel="profile" href="http://osprotocol.com" />
  <meta property="os:repo" content="https://github.com/RichardLitt/wordhoardpress.com" />
  <meta property="os:rcs_type" content="git" />
  <meta property="os:src" content="[email protected]:RichardLitt/wordhoardpress.com.git" />

from centrarium.

bencentra avatar bencentra commented on August 21, 2024

The first two are Facebook and Twitter, right? For og:image and twitter:image, is "assets/twitter_360.png" something specific to your site? It should be configurable in either _config.yml or on a page-by-page basis in the front matter.

If you want to include the Open Source Protocol stuff, I'd add fields in _config.yml for users to configure and (optionally) include them.

from centrarium.

bencentra avatar bencentra commented on August 21, 2024

If you're willing to make it more customizable (at least site-wide in _config.yml), a PR would be greatly appreciated!

from centrarium.

RichardLitt avatar RichardLitt commented on August 21, 2024

I'll make another PR for OSP after this, I think these should be included anyway, still a bit biased about OSP because, you know, it's mine. You sure you cool with that?

from centrarium.

bencentra avatar bencentra commented on August 21, 2024

I hadn't heard of OSP until just now, and I didn't realize you had worked on it!

I'm totally cool with adding OSP, I just want it to be configurable. If the consumer of the theme wants to use OSP to link to their source, they can add the fields in _config.yml in the protocols section you added in #5 to generate the meta tags. If the fields aren't found, the corresponding meta tags shouldn't be included.

You should also definitely update the README to mention OSP so people will use it. Feel free to link back to your site or any pages describing what OSP is.

from centrarium.

RichardLitt avatar RichardLitt commented on August 21, 2024

PR'ed. Cool, thanks. I added a link in the config to explain what it is, might be good to add a section to the README.

from centrarium.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.