title: Property 'find' does not exist on type 'typeof import("c:/productcatelog2/src/client/app/shared/product.model")'.ts'
body: <p>iam a newbee here ,i managed to apply route for the created products but it is unable to view the specific product while clicked</p>
  <p><strong>product-details.component.html</strong></p>
  <p>here product-details has routed then &quot;.find&quot; emmits error .</p>
  <pre><code>import { Component, HostBinding, Input, OnInit } from '@angular/core';
  import { ActivatedRoute } from '@angular/router';
  //import { Product } from '../shared/product.model';
  //import { Observable } from 'rxjs';
  //import { ApiService }from '../shared/api.service';
  
  //import { products } from '../products';
  import * as products from '../shared/product.model';
  
  @Component({
    selector: 'app-product-details',
    templateUrl: './product-details.component.html',
    styleUrls: ['./product-details.component.css']
  })
  export class ProductDetailsComponent implements OnInit
  {
    //products: Array&lt;Product&gt;;
    product;
  
  
    constructor(
      private route : ActivatedRoute,
     // private http : ApiService
    ) { }
  
    ngOnInit() {
  
      const routeParams = this.route.snapshot.paramMap;
      const productitemNameFromRoute = String(routeParams.get('productitemName'));
  
  
      this.product = products.find(product =&gt; product.itemName === productitemNameFromRoute);
  
      }
    }
  
  </code></pre>
  <p><strong>product.model.ts</strong></p>
  <pre><code>export interface Product 
  {
    itemName: string;
    category: string;
    price: number;
    quantity: number;
    isStockAvailable:boolean;
    photoUrl:string;
  }
  </code></pre>
  <p><strong>tsconfig.json</strong></p>
  <p>here is the tsconfig.json  are its need to modify</p>
  <pre><code>{
    &quot;compileOnSave&quot;: false,
    &quot;compilerOptions&quot;: {
      &quot;baseUrl&quot;: &quot;./&quot;,
      &quot;outDir&quot;: &quot;./dist/out-tsc&quot;,
      &quot;sourceMap&quot;: true,
      &quot;declaration&quot;: false,
      &quot;downlevelIteration&quot;: true,
      &quot;experimentalDecorators&quot;: true,
      &quot;module&quot;: &quot;esnext&quot;,
      &quot;moduleResolution&quot;: &quot;node&quot;,
      &quot;importHelpers&quot;: true,
      &quot;lib&quot;: [
        &quot;es6&quot;,
        &quot;dom&quot;
      ],
      &quot;target&quot;: &quot;es6&quot;
     },
    &quot;angularCompilerOptions&quot;: {
      &quot;fullTemplateTypeCheck&quot;: true,
      &quot;strictInjectionParameters&quot;: true
    }
  }
  </code></pre>