mirror of
https://github.com/kingomarnajjar/gatsby-starter-netlify-cms.git
synced 2026-07-25 22:27:24 +10:00
fix : Change map key to uuid
This commit is contained in:
parent
2ef03261e3
commit
272f15d2c2
1 changed files with 3 additions and 2 deletions
|
|
@ -1,10 +1,11 @@
|
|||
import React from 'react'
|
||||
import PropTypes from 'prop-types'
|
||||
import { v4 } from 'uuid'
|
||||
|
||||
const Testimonials = ({ testimonials }) => (
|
||||
<div>
|
||||
{testimonials.map((testimonial,index) => (
|
||||
<article key={index} className="message">
|
||||
{testimonials.map(testimonial => (
|
||||
<article key={v4()} className="message">
|
||||
<div className="message-body">
|
||||
{testimonial.quote}
|
||||
<br />
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue