Very clear explanation, in short time, source code available, timestamps. A lot of helpful tutorials on this channel. THANK YOU SO MUCH FOR THIS! Subscribed!
Hello , very clear explanation and tutorial. Will it work the same way in Angular 18 ? It seems that httpclient module obsolete . Any advice ? Thank you
Fetch API is Javascript and is based on promises. Angular http is the core part of Angular and is based on Observables. I highly recommend you to stick to Angular approaches.
Hi i have error No overload matches this call. Overload 1 of 3, '(observer?: Partial | undefined): Subscription', gave the following error. Type '(movies: Movie[]) => void' has no properties in common with type 'Partial'.
Hey, idk is this still actual, but will be useful for those who will face this problem in the future. Rxjs changed from version 5 to version 6, HttpClientModule introduced serialized JSON support. So you can use Generic, like '.get'
Thank you for the videos. I'm new to Angular and I think your teaching is very good. I have a question: you created the http variable in the constructor. What is the difference than creating it outside the constructor?
I'm happy that you like my videos! It's not possible to create http variable outside or constructor arguments. It's a way how it is designed in Angular. Because it's not just "creating a variable". We inject dependency in our service or component.
Nope. And by the way I don't use Iterm anymore. As I don't need 90% of features that iterm2 has because of tmux I switched to alacritty which works much faster and easier to configure.
Thanks a lot for this videos, just a feedback, I think you need just to speed up a bit when you talk because you are really speaking too slow where it makes me sleep. (Please don't understand me wrong)
Thanks for the feedback. I know about this problem but as English not my native language it's tricky. As a quick fix I can recommend watching my videos on 1.25x speed. People write that it's more comfortable.
Hi I have an error here : Error: src/app/app.component.ts:19:18 - error TS2769: No overload matches this call. Overload 1 of 3, '(observer?: Partial | undefined): Subscription', gave the following error. Type '(users: UserInterface[]) => void' has no properties in common with type 'Partial'. Overload 2 of 3, '(next: (value: Object) => void): Subscription', gave the following error. Argument of type '(users: UserInterface[]) => void' is not assignable to parameter of type '(value: Object) => void'. Types of parameters 'users' and 'value' are incompatible. The 'Object' type is assignable to very few other types. Did you mean to use the 'any' type instead? Type 'Object' is missing the following properties from type 'UserInterface[]': length, pop, push, concat, and 28 more. Overload 3 of 3, '(next?: ((value: Object) => void) | null | undefined, error?: ((error: any) => void) | null | undefined, complete?: (() => void) | null | undefined): Subscription', gave the following error. Argument of type '(users: UserInterface[]) => void' is not assignable to parameter of type '(value: Object) => void'. Types of parameters 'users' and 'value' are incompatible. Type 'Object' is not assignable to type 'UserInterface[]'. The 'Object' type is assignable to very few other types. Did you mean to use the 'any' type instead? 19 .subscribe((users: UserInterface[]) => { helpp :((
how to unit test json file data having multiple id's of users in angular ? user.json => [ { "id": "123", "email": "@sdafs.com", "isActive": "tru }, { "id": "234", "email": "@kjsdk.com", "isActive": false } ] specs.ts=> it("should be",()=>{ expect(???????).tobe(??????)}) I have used httpclient method as you are doing in this video,but I have to do unit testing of user data present in json file, can you help me ?
I can't answer it in several lines. Testing is quite a bit topic Here is a good article about how to mock and test httpClient blog.angulartraining.com/how-to-write-unit-tests-for-angular-code-that-uses-the-httpclient-429fa782eb15
WATCH NEXT: Angular Interview Questions and Answers - Dominate Your Next Interview - ruclips.net/video/5A_YKlVWMPo/видео.htmlsi=2DCn7yspEAAJ2H6l
Very clear explanation, in short time, source code available, timestamps.
A lot of helpful tutorials on this channel. THANK YOU SO MUCH FOR THIS! Subscribed!
Glad it was helpful!
Hello , very clear explanation and tutorial. Will it work the same way in Angular 18 ? It seems that httpclient module obsolete . Any advice ? Thank you
Hi, yes it will. We still use Httpclient service in Angular 18 to get data. The only difference that we provide it in appConfig as provideHttpClient()
Thanks , will try .
great explaination
Thank you!
Thanks for the video! I have a question, why you are not using fetch API? I have tried it, and it's working.
Fetch API is Javascript and is based on promises. Angular http is the core part of Angular and is based on Observables. I highly recommend you to stick to Angular approaches.
Hello, thanks for the tutorial, is it possible to run json server on github pages somehow?
Hi unfortunately I didn't try that so I can't help
Hi i have error
No overload matches this call.
Overload 1 of 3, '(observer?: Partial | undefined): Subscription', gave the following error.
Type '(movies: Movie[]) => void' has no properties in common with type 'Partial'.
Hi can you post your code?
Hey, idk is this still actual, but will be useful for those who will face this problem in the future. Rxjs changed from version 5 to version 6, HttpClientModule introduced serialized JSON support. So you can use Generic, like '.get'
Thank you very much for your video.
I'm happy that you like it!
recently I can't use the type inside the subscription, why?
No idea. You need to debug it.
Thank you for the videos. I'm new to Angular and I think your teaching is very good. I have a question: you created the http variable in the constructor. What is the difference than creating it outside the constructor?
I'm happy that you like my videos! It's not possible to create http variable outside or constructor arguments. It's a way how it is designed in Angular. Because it's not just "creating a variable". We inject dependency in our service or component.
Can we deploy angular app with json server
Will json server api's work after deployment
Yes sure. It's just a node process. Just run it like locally and it will work. But this is not a production solution of course.
wich app use for coding ?
wich color theme?
It's gruvbox. Here is a video about an editor.
ruclips.net/video/YrLiugDhCuk/видео.html
Is it iTerm or default Mac OS terminal?
Nope. And by the way I don't use Iterm anymore. As I don't need 90% of features that iterm2 has because of tmux I switched to alacritty which works much faster and easier to configure.
@@MonsterlessonsAcademy can u create a video about your setup?
@@serhiitachuk Later for sure but now I'm trying to get more subscribers and I don't think that this video will be too popular.
Can we deploy angular app with json server
Will json server api's work after deployment
Please reply if u have any idea
Yes sure. It's just a node process. Just run it like locally and it will work. But this is not a production solution of course.
Thanks Bro
Any time
Thank you
You're welcome!
Спасибо. Но есть ли где на русском вещаешь?
Нет
Thanks a lot for this videos, just a feedback, I think you need just to speed up a bit when you talk because you are really speaking too slow where it makes me sleep. (Please don't understand me wrong)
Thanks for the feedback. I know about this problem but as English not my native language it's tricky. As a quick fix I can recommend watching my videos on 1.25x speed. People write that it's more comfortable.
@@MonsterlessonsAcademy I like the speed of your speech. I understand every word and can follow.
Hi I have an error here :
Error: src/app/app.component.ts:19:18 - error TS2769: No overload matches this call.
Overload 1 of 3, '(observer?: Partial | undefined): Subscription', gave the following error.
Type '(users: UserInterface[]) => void' has no properties in common with type 'Partial'.
Overload 2 of 3, '(next: (value: Object) => void): Subscription', gave the following error.
Argument of type '(users: UserInterface[]) => void' is not assignable to parameter of type '(value: Object) => void'.
Types of parameters 'users' and 'value' are incompatible.
The 'Object' type is assignable to very few other types. Did you mean to use the 'any' type instead?
Type 'Object' is missing the following properties from type 'UserInterface[]': length, pop, push, concat, and 28 more.
Overload 3 of 3, '(next?: ((value: Object) => void) | null | undefined, error?: ((error: any) => void) | null | undefined, complete?: (() => void) | null | undefined): Subscription', gave the following error.
Argument of type '(users: UserInterface[]) => void' is not assignable to parameter of type '(value: Object) => void'.
Types of parameters 'users' and 'value' are incompatible.
Type 'Object' is not assignable to type 'UserInterface[]'.
The 'Object' type is assignable to very few other types. Did you mean to use the 'any' type instead?
19 .subscribe((users: UserInterface[]) => {
helpp :((
same error .. .u got answer ?
how to unit test json file data having multiple id's of users in angular ?
user.json =>
[
{
"id": "123",
"email": "@sdafs.com",
"isActive": "tru
},
{
"id": "234",
"email": "@kjsdk.com",
"isActive": false
}
]
specs.ts=>
it("should be",()=>{
expect(???????).tobe(??????)})
I have used httpclient method as you are doing in this video,but I have to do unit testing of user data present in json file, can you help me ?
I can't answer it in several lines. Testing is quite a bit topic
Here is a good article about how to mock and test httpClient
blog.angulartraining.com/how-to-write-unit-tests-for-angular-code-that-uses-the-httpclient-429fa782eb15