-
-
Notifications
You must be signed in to change notification settings - Fork 8.5k
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
Tabs not working on Docusaurus Static build #9853
Comments
There is no "postprocess" thing in Docusaurus This likely creates hydration mismatches, and you should not alter the output html otherwise the React app can't hydrate. You should provide a https://docusaurus.new repro, giving us a clear way to see the problem in action for a given Docusaurus version. Until then I consider it's not a bug but a bad usage of Docusaurus Tabs work perfectly fine for hundreds of sites, including ours, so you must be doing something unusual. |
The official documentation specifically calls for a post-process: And there is a Here's the website for it: Please re-open this issue. It is working on hundreds of websites because, as I said, it works on the dev server. But it is not working offline. |
@ColinLondon Whatever it is that you are using, it is not Docusaurus. Please send your issue to their project because they are using Docusaurus in a way that we neither endorse nor recommend. |
@Josh-Cena Thanks for that. I never realised. Their site is identical to the official Docusaurus one. I guess it's back to square one to figure out how to make Docusaurus work offline (I'm not a dev). Thanks again. |
Indeed it's not our project, it's a project from @andrigamerita introduced here: We can't support you using it. It looks quite new and experimental so although the approach could be interesting I'm not sure I'd recommend it for now, unless you clearly understand the tradeoffs you make here (and you'd rather be a dev for that). |
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
I am using Docusarus Static as an offline template. I have a tabs arrangement as a test in a
.md
file:This runs just fine on the development server (
npm run start
), with the tabs switching on click, as expected.But when I build the site (
npm run build+postprocess
) the tabs display okay, but I cannot client to switch tabs.Reproduce by using the code segment above and then run with the commands shown.
Reproducible demo
No response
Steps to reproduce
Step 1. Using this code on a page:
Step 2: Run
npm run start
. Tabs work as expected.Step 3: Run
npm run build+postprocess
. In the build, the tabs display okay, but with no tab switching.Expected behavior
Tabs not switchable on build.
Actual behavior
No interaction.
Your environment
Self-service
The text was updated successfully, but these errors were encountered: