title: Angular 13 Call store dispatch Action in strore.pipie inside component
body: <p>im working in Angular 13 and ngRxStore, inside my component i want to read my store and dispatch a new Action with data returned from my store , this is my code :</p>
  <pre><code>productState$ :Observable&lt;ProductsState&gt;  | null = null;
  
  constructor(private store: Store&lt;any&gt;) { }
  
  ngOnInit(): void {
      
  this.productState$ = this.store.pipe(
     map((state)=&gt; state.appProductState )
     
     // here i want to dispatch action using this.store.dispatch(MyAction(currentProduct.id))
  );
  
  }
  </code></pre>
  <p>and this is my state object :</p>
  <pre><code>export interface ProductsState {
      currentProduct:Product | null
      errorMessage:string,
      dataState:ProductSatateEnum
  }
  </code></pre>
  <p>anyone can guide my how i can dispatch my action correctly with data returned from store inside the pipe().</p>