Skip to content

Commit

Permalink
remove spread operator from <Link> component (vercel#263)
Browse files Browse the repository at this point in the history
* remove spread operator from <Link> component

* Remove props destructuring

Co-authored-by: Luis Alvarez <[email protected]>
  • Loading branch information
gondar00 and lfades authored Jul 30, 2021
1 parent 34d0a0b commit 44ce537
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions components/product/ProductCard/ProductCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import Image, { ImageProps } from 'next/image'
import WishlistButton from '@components/wishlist/WishlistButton'
import usePrice from '@framework/product/use-price'
import ProductTag from '../ProductTag'

interface Props {
className?: string
product: Product
Expand All @@ -23,7 +24,6 @@ const ProductCard: FC<Props> = ({
className,
noNameTag = false,
variant = 'default',
...props
}) => {
const { price } = usePrice({
amount: product.price.value,
Expand All @@ -38,7 +38,7 @@ const ProductCard: FC<Props> = ({
)

return (
<Link href={`/product/${product.slug}`} {...props}>
<Link href={`/product/${product.slug}`}>
<a className={rootClassName}>
{variant === 'slim' && (
<>
Expand Down

0 comments on commit 44ce537

Please sign in to comment.