hig
hig copied to clipboard
When using the top nav logo component with server side rendering, warnings appear in the console
index.js:1 Warning: Prop dangerouslySetInnerHTML did not match. Server: "<img src="/static/autobadlogo-cropped.png" alt="autobad logo" width="30"><h1 style="display:inline-block;margin:0;font-size:16px;line-height:16px;font-weight:400" class="css-oswdbz">utoBAD" Client: ""
I looked in the presenter and found
https://github.com/Autodesk/hig/blob/development/packages/top-nav/src/presenters/LogoPresenter.js#L34
However I'm not quite sure what's going on. Needs further investigation. It might require {{__html: ''}}
code snippet
<TopNav
logo={
// There is a logo component, but I found I received errors while using it
<Logo link='/'>
<img src="/static/autobadlogo-cropped.png" alt="autobad logo" width="30"/><LogoText>utoBAD</LogoText>
</Logo>
} />