(1) Instead of inline if conditions:
|
{settings.logo ? <Logo src={settings.logo} alt={settings.name} /> : null} |
Use the && operator consistently(IIRC we already discussed this):
{settings.logo && <Logo src={settings.logo} alt={settings.name} />}
(2) Instead of && to ensure object fields:
|
{settings.header && settings.header.technologies ? ( |
Use the optional chaining operator:
{settings?.header?.technologies && ( ... )}
We may also find further improvements.
(1) Instead of inline if conditions:
dotdev/src/components/Header/Header.js
Line 39 in e1fd40f
Use the
&&operator consistently(IIRC we already discussed this):(2) Instead of
&&to ensure object fields:dotdev/src/components/Header/Header.js
Line 42 in e1fd40f
Use the optional chaining operator:
We may also find further improvements.