import { PureComponent } from 'react';
// we use the SourceComponent alias to explicitly import from the parent theme
// (if we would use Component/ProductCard/... instead, we would be trying to import
// the current file, which would result in an error)
import { ProductCard as SourceProductCard } from 'SourceComponent/ProductCard/ProductCard.component';
// we imported the original ProductCard class defined in the parent theme.
// we aliased the import to `SourceProductCard` to indicate that SourceProductCard
// is the parent theme version of the class
// you should always copy over the namespace declaration when overriding an existing class
// to avoid breaking plugins
/** @namespace Component/ProductCard/Component */
export class ProductCard extends SourceProductCard { // we can now extend SourceProductCard,
// and override any methods we want to change
// this method overrides the default implementation provided in the original ProductCard class
// returning null in a React component means rendering nothing
// we now export the extended and modified version of the class
export default ProductCard;