Logo: React
A wrapper component around the CDN-hosted logos for each brand.
Installation
Before you can start using the @mediahuis/chameleon-react
component, you’ll need to install it, for more information check: Getting started for developers.
With that done, you’re now ready to implement the component in your application.
import { Logo } from '@mediahuis/chameleon-react';
export default function Example() {
return <Logo />;
}
Properties
Property | Type | Default | Required | Description |
---|---|---|---|---|
alt | String | - | No | Sets the native image alt attribute. |
className | String | - | No | Allows extending the class names of the Logo component. |
extension | 'png' | 'svg' | 'svg' | No | The file extension of the image. |
name | String | 'logo-main' | No | Controls which logo is displayed. You can access Logo variations by using "variations.VARIATION_NAME". |
version | String | packageVersion | No | Controls which version of the logo is displayed. This conforms to any version number of chameleon as specified in package.json of the theme. |