Skip to content

params in showing undefined #220

@gur0297

Description

@gur0297

please help me out because params not defined .

import React from 'react'
// import {Link} from 'react-router-dom';
// import {Row , Col ,Image , ListGroup , Card , Button } from "react-bootstrap";
// import Rating from "../components/Rating";
import products from "../products";

const ProductScreen = ({ match }) => {
const product = products.find(p => p._id === match.params.id);
return (

{product.name}

)
}

export default ProductScreen

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions