import React from 'react'; import {Link} from 'react-router-dom' export default class MoreInfo extends React.Component { render() { const {his,data} = this.props; const doctor = data.find(el => el._id === his.match.params.doctor); const service = data.find(el => el._id === his.match.params.service); console.log (this.props, doctor) return (
{doctor &&

{doctor.name}

Duration:{doctor.profession}

{doctor.description}

Price:{doctor.experience}грн.

Make an appointment
} { service &&
{service.name}

Duration:{service.duration}h

{service.description}

Price:{service.price}грн.

Make an appointment
}
); } }