Head Metadatas
Docusaurus automatically sets useful page metadatas in <html>
, <head>
and <body>
for you.
It is possible to add extra metadatas (or override existing ones) by using the <head>
tag in Markdown files:
markdown-features-head-metadatas.mdx
---
id: head-metadatas
title: Head Metadatas
---
<head>
<html className="some-extra-html-class" />
<body className="other-extra-body-class" />
<title>Head Metadatas customized title!</title>
<meta charSet="utf-8" />
<meta name="twitter:card" content="summary" />
<link rel="canonical" href="https://docusaurus.io/docs/markdown-features/head-metadatas" />
</head>
# Head Metadatas
My text
tip
This <head>
declaration has been added to the current Markdown doc, as a demo.
Open your browser DevTools and check how this page's metadatas have been affected.
note
This feature is built on top of the Docusaurus <Head>
component.
Refer to react-helmet for exhaustive documentation.