index.tsx 298 B

123456789101112
  1. import React from 'react'
  2. import AudioPlayer from './AudioPlayer'
  3. type Props = {
  4. srcs: string[]
  5. }
  6. const AudioGallery: React.FC<Props> = ({ srcs }) => {
  7. return (<><br/>{srcs.map((src, index) => (<AudioPlayer key={`audio_${index}`} src={src}/>))}</>)
  8. }
  9. export default React.memo(AudioGallery)