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

add the social medias card metadata for the webpages, optional #9

Closed
Thecarisma opened this issue May 30, 2020 · 1 comment
Closed
Labels
enhancement New feature or request

Comments

@Thecarisma
Copy link
Owner

Thecarisma commented May 30, 2020

<meta name="twitter:card" content="summary" />
<meta name="twitter:site" content="@flickr" />
<meta name="twitter:title" content="Small Island Developing States Photo Submission" />
<meta name="twitter:description" content="View the album on Flickr." />
<meta name="twitter:image" content="https://farm6.staticflickr.com/5510/14338202952_93595258ff_z.jpg" />

can be set in the conf.py as

html_theme_options = {
   "has_twitter_meta_data": True,
   "twitter_handle": "@themata",
   "twitter_meta_data": {
      "card": "",
      "site": "",
      "title": "",
      "description": "",
      "image": "",
   }
}

The default card value is summary, default site is the twitter handle of the website, the default title is the title of the project, the default description is the website description the default image is the site icon. The fields are optional.

See https://cards-dev.twitter.com/validator https://developer.twitter.com/en/docs/tweets/optimize-with-cards/overview/summary

@Thecarisma Thecarisma added the enhancement New feature or request label May 30, 2020
@Thecarisma Thecarisma changed the title add the twitter card metadata for the webpages, optional add the social medias card metadata for the webpages, optional Jul 3, 2020
@Thecarisma
Copy link
Owner Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant