question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

I can't get the theme config logo config to work

See original GitHub issue

Question

Description In the default theme README it states:

// doczrc.js
export default {
  themeConfig: {
    logo: {
      src: '/path/of/my/logo',
      width: 150
    }
  }
}

I have tried with all kind of absolute and relative paths and I can’t manage to display my logo. I guess it’s because it doesn’t get bundled ?

My logo is located at ./src/logo.svg and my doczrc.js looks like this:

export default {
    src: "./src",
    ...
    themeConfig: {
       ...
        logo: {
            src: "./logo.svg",
            width: 150
        }
    },
};

Thank you for your help ! 😄

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:7 (3 by maintainers)

github_iconTop GitHub Comments

5reactions
enzofereycommented, Nov 27, 2018

Got a solution 🎉

Thanks to this comment I learnt that Docz supports a public folder, so my config now looks like this:

export default {
  src: "./src",
  public: "./src/public",
  ...
  themeConfig: {
     ...
      logo: {
          src: "/public/logo.svg",
          width: 150
      }
   },
};

It works great ! I feel like the documentation of the default theme should be updated to either a working solution without using public folder (I don’t know of any) and this public folder thing should be documented in the main package.

I can’t really find any page on the website where configs like public or htmlContent are documented. I would like to do it, but where should it be placed ?

2reactions
JulienDemarquecommented, Jun 13, 2019

Seems the public folder thing is still not properly documented… I had to came here to find the solution. Any update to the documentation soon?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Theme configuration - Docusaurus
This configuration applies to all main themes.
Read more >
Using a logo.png file in the theme folder doesn't work - Drupal
svg from my starterkit folder and put a logo.png. It should be picked up, but it isn't. Apparently in the config, features.logo isn't...
Read more >
How to configure global theme and logo in Microsoft 365 ribbon
In this article, I provide instructions on how to configure global theme in Microsoft 365 to match corporate branding and logo.
Read more >
How do I set the theme logo? - Drupal Answers
For regular themes, you can just go to the appearance page, go to the settings tab and deselect Use ...
Read more >
Theme configuration guide - Good Grants Help Centre
To get started, open the Manage workspace and go to Settings > General > Theme. Home. In Good Grants, the home page refers...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found