Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

I am getting error called no overload matches this call #8

Open
kishore0995 opened this issue Jan 25, 2021 · 1 comment
Open

I am getting error called no overload matches this call #8

kishore0995 opened this issue Jan 25, 2021 · 1 comment

Comments

@kishore0995
Copy link

At this line in cart.component.ts ( this.msg.getMsg().subscribe((product:Product) =>) i am getting error how to solve this

No overload matches this call.
Overload 1 of 5, '(observer?: NextObserver | ErrorObserver | CompletionObserver | undefined): Subscription', gave the following error.
Argument of type '(product: Product) => void' is not assignable to parameter of type 'NextObserver | ErrorObserver | CompletionObserver | undefined'.
Property 'complete' is missing in type '(product: Product) => void' but required in type 'CompletionObserver'.
Overload 2 of 5, '(next?: ((value: unknown) => void) | undefined, error?: ((error: any) => void) | undefined, complete?: (() => void) | undefined): Subscription', gave the following error.
Argument of type '(product: Product) => void' is not assignable to parameter of type '(value: unknown) => void'.
Types of parameters 'product' and 'value' are incompatible.
Type 'unknown' is not assignable to type 'Product'.ts(2769)

@veliyat
Copy link
Owner

veliyat commented Sep 20, 2021

I think this is related to some coding error, kindly compare my code of the specific video with yours. You can get code related to all the parts from this google drive link.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants