docusaurus-theme-classic > Heading's className prop does nothing #8327
Labels
bug
An error in the Docusaurus core causing instability or issues with its execution
good first issue
If you are just getting started with Docusaurus, this issue should be a good place to begin.
Have you read the Contributing Guidelines on issues?
Prerequisites
npm run clear
oryarn clear
command.rm -rf node_modules yarn.lock package-lock.json
and re-installing packages.Description
The
<Heading>
component indocusaurus-theme-classic
can be given aclassName
prop:However, the component's manual
className=clsx(...)
prop ignoresprops.className
:docusaurus/packages/docusaurus-theme-classic/src/theme/Heading/index.tsx
Lines 26 to 33 in 7ffa9f7
This means any
className
added in user-land is ignored.Reproducible demo
https://github.com/typescript-eslint/typescript-eslint/pull/5951/files#diff-3b034ddb6525c7b93f97ced8a696c78c1837f072b9d1e70c46049675e0e09bf4R112-R116
Steps to reproduce
yarn
->yarn start
to
...Expected behavior
The
className
should be added to theclsx
inHeading
.Actual behavior
The
className
is ignored.Your environment
main
Self-service
The text was updated successfully, but these errors were encountered: