Have you read the Contributing Guidelines on issues?
Prerequisites
Description
The theme inconsistently wraps the title of a doc page into <header>: Only when a synthetic title is rendered, it is being wrapped into <header>. Non-synthetic titles are not wrapped into <header>.
Relevant code:
|
<header> |
|
<Heading as="h1">{syntheticTitle}</Heading> |
|
</header> |
Reproducible demo
https://codesandbox.io/s/dazzling-panini-566sqf
Steps to reproduce
Go to "Tutorial Intro" page: Title not wrapped in <header>
Go to "Tutorial - Basics" -> "Create a Page": Title is wrapped in <header>
Expected behavior
The doc title should either always, or never, be wrapped in <header>.
Actual behavior
The doc page title is wrapped in <header> depending on whether it is a synthetic title or not.
Your environment
- Docusaurus version used: 2.2.0
Self-service
Have you read the Contributing Guidelines on issues?
Prerequisites
npm run clearoryarn clearcommand.rm -rf node_modules yarn.lock package-lock.jsonand re-installing packages.Description
The theme inconsistently wraps the title of a doc page into
<header>: Only when a synthetic title is rendered, it is being wrapped into<header>. Non-synthetic titles are not wrapped into<header>.Relevant code:
docusaurus/packages/docusaurus-theme-classic/src/theme/DocItem/Content/index.tsx
Lines 41 to 43 in 024474a
Reproducible demo
https://codesandbox.io/s/dazzling-panini-566sqf
Steps to reproduce
Go to "Tutorial Intro" page: Title not wrapped in
<header>Go to "Tutorial - Basics" -> "Create a Page": Title is wrapped in
<header>Expected behavior
The doc title should either always, or never, be wrapped in
<header>.Actual behavior
The doc page title is wrapped in
<header>depending on whether it is a synthetic title or not.Your environment
Self-service