Skip to content
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

[v2] Alpha 66 breaks classic site without logo #3610

Closed
SamChou19815 opened this issue Oct 19, 2020 · 0 comments · Fixed by #3611
Closed

[v2] Alpha 66 breaks classic site without logo #3610

SamChou19815 opened this issue Oct 19, 2020 · 0 comments · Fixed by #3611
Labels
bug An error in the Docusaurus core causing instability or issues with its execution

Comments

@SamChou19815
Copy link
Contributor

🐛 Bug Report

In #3394, we no longer give logo field a dummy empty object if it's undefined, which will cause it to crash at line 19:

const {
navbar: {logo},
} = useThemeConfig();
const {isDarkTheme} = useThemeContext();
const logoLink = useBaseUrl(logo.href || '/');

Have you read the Contributing Guidelines on issues?

Yes

To Reproduce

Upgrade a classic site without logo to alpha-66.

Expected behavior

Sites without logo property should continue to work

Actual Behavior

Blank screen with js error:

Screen Shot 2020-10-19 at 14 47 37

Your Environment

  • Docusaurus version used: v2-alpha-66
  • Environment name and version (e.g. Chrome 78.0.3904.108, Node.js 10.17.0): Chrome
  • Operating system and version (desktop or mobile): macOS

Reproducible Demo

https://github.com/SamChou19815/website/tree/master/packages/blog

Bump it to alpha-66, and yarn start.

@SamChou19815 SamChou19815 added bug An error in the Docusaurus core causing instability or issues with its execution status: needs triage This issue has not been triaged by maintainers labels Oct 19, 2020
@Josh-Cena Josh-Cena removed the status: needs triage This issue has not been triaged by maintainers label Mar 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug An error in the Docusaurus core causing instability or issues with its execution
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants