facebook / docusaurus

Easy to maintain open source documentation websites.
https://docusaurus.io
MIT License
55.96k stars 8.4k forks source link

"footer.logo.alt" is not allowed to be empty #3816

Closed aarongarciah closed 3 years ago

aarongarciah commented 3 years ago

šŸ› Bug Report

This is exactly the same issue as https://github.com/facebook/docusaurus/issues/3350, but this time in the footer config instead of the navbar config.

When I use an empty string for footer.logo.alt in my config, I get the following validation error:

ValidationError: "footer.logo.alt" is not allowed to be empty

Have you read the Contributing Guidelines on issues?

Yes

To Reproduce

  1. Create a new Docusarus v2 project.
  2. Set footer.logo.alt in themeConfig in docusaurus.config.js to ''.
  3. Run npm start.

Expected behavior

The website to start just fine with the footer logo having an empty alt="" attribute.

Actual Behavior

The site doesn't compile and an error is shown in the terminal output:

A validation error occured.
The validation system was added recently to Docusaurus as an attempt to avoid user configuration errors.
We may have made some mistakes.
If you think your configuration is valid and should keep working, please open a bug report.

ValidationError: "footer.logo.alt" is not allowed to be empty

Your Environment

Reproducible Demo

  1. Clone https://github.com/aarongarciah/docusaurus-footer-logo-alt
  2. yarn install
  3. yarn start
  4. Check the terminal output and see the ValidationError: "footer.logo.alt" is not allowed to be empty error

Or with a CodeSandbox account:

  1. Go to https://codesandbox.io/s/nice-torvalds-y57bu?file=/docusaurus.config.js
  2. Fork the sandbox
  3. Check the terminal output (once it finishes installing dependencies) and see the ValidationError: "footer.logo.alt" is not allowed to be empty error
iamrubayet commented 3 years ago

can i work on this ??????

aarongarciah commented 3 years ago

can i work on this ??????

@iamrubayet this was solved via https://github.com/facebook/docusaurus/pull/3817