Babel website migration #6648
Replies: 3 comments 5 replies
-
Docusaurus v2 is a SPA and the way you integrate third-party scripts may be different, including inserting scripts on the page using a To be able to help you, it would be preferable that you setup a branch on your fork with deploy previews so that we can try to submit a PR to it and fix your issue. You can signup on Netlify/Vercel to set this up. If you are looking for some integration inspiration, take a look at this PR where I add a Relay compiler playground to a Docusaurus page: |
Beta Was this translation helpful? Give feedback.
-
https://github.com/harish-sethuraman/website/tree/v2 This is the fork I’m working on and the branch is Also the repl is a separate bundle all together so if you are trying to run babel website run |
Beta Was this translation helpful? Give feedback.
-
Im closing this as the babel site got shipped already. I missed to close this discussion. Thanks for all your help 😉. |
Beta Was this translation helpful? Give feedback.
-
I'm trying to migrate the babel website to docusaurus v2. We have a
repl
page in which we load-scripts needed for repl. This works fine with v1 but v2 doesn't load-scripts. I see that we have to add scripts to thedocusaurus.config.js
for loading the scripts. But the scripts in that particular page are isolated and not required for any other routes. I tried using@docusaurus/Head
andreact-helmet
but not luck either.This is the code for that particular page:
https://github.com/babel/website/blob/main/website/pages/en/repl.js
Beta Was this translation helpful? Give feedback.
All reactions