Custom event Binding: @Output Decorator | Data Binding | Angular 12+

Поділитися
Вставка
  • Опубліковано 2 жов 2024
  • In this lecture, you are going to learn about custom event binding in angular. Using custon event binding, we can pass data from child component to parent component class.
    To do this, we create a custom event and we bind it with @Output decorator. Then we raise the event and in parent class we create a method to handle that event.
    Let's understand custom event binding with an example.

КОМЕНТАРІ • 39

  • @bhupendrasingh8570
    @bhupendrasingh8570 Рік тому +18

    I watched each and every video without skipping and i am going to watch whole playlist.i just want to say thank you very very much for this playlist your way of explanation is awesome.i gain confidence after watching your video..this is top of the best channel on UA-cam .i learnt alot from you sir..huge huge respect for you🙌

  • @PratikP-j1f
    @PratikP-j1f Рік тому +10

    Thanks for creating such beautiful lecture series keep it up regular

    • @iamnoob7593
      @iamnoob7593 Рік тому +5

      Superb man , We people have to support such amazing content creaters

    • @PratikP-j1f
      @PratikP-j1f Рік тому

      Teacher is indeed a gem! Never hesitate to appreciate a thing that add value to your life@@iamnoob7593

  • @jjuliefrance
    @jjuliefrance Рік тому +10

    Yes, top of the best channel on UA-cam ! Each lecture is a master one.

  • @salsal-dd1dq
    @salsal-dd1dq Рік тому +5

    Best explaining style by far, even better than paid angular courses I watched before. Keep up the great work Sir!

  • @andyserrato
    @andyserrato 11 місяців тому +3

    Thanks! this is a well crafted course

  • @RamanaVenkata-tx9tg
    @RamanaVenkata-tx9tg Рік тому +4

    Top of the angular course in world

  • @mohammedabdulaziz3658
    @mohammedabdulaziz3658 2 роки тому +4

    Dynamic example sir..thank you.
    Awesome explanation, even I don't know some core point of coding & you are covering all those things.

  • @silvertoothdevlog6102
    @silvertoothdevlog6102 Рік тому +3

    Up until this topic I was getting everything but this one after that @output... I will have to watch this video a few more times apparently

  • @shubhamkumar-re8xx
    @shubhamkumar-re8xx 2 роки тому +3

    @procademy Please can you explain whether only using course.type with ngIf directive at line no. 11 in course.component.html would have worked or not? As from my point of view course.type do contain 'All' also.

    • @ezzybrezzy-xl3wd
      @ezzybrezzy-xl3wd Рік тому +3

      course.type consists of type='free' and type='premium', there is not type as all!:)

  • @lacertezzadellapena
    @lacertezzadellapena 2 роки тому +3

    Just a question, @proacademy. Could you please explain why in filterRadioButtonSelectionChanged: EventEmitter = new EventEmitter();
    the type of the property (EventEmitter) has ''?
    Many thanks in advance

    • @procademy
      @procademy  2 роки тому +8

      EventEmitter is a class of generic type. In the bracket's we specify the type of data which the event is going to emit. In our example, we emmited event data of type string that's why we specified . If we wanted to emit data of number type, then we would have specified .
      In simple terms, an event can emit data of any type, but it is mandatory to specify in advance, which type of data event will emit. This is for type safety.
      If we specify that our event will emit data of string type, but in actual it emits data of number type, typescript will throw an error. In this way, it provides type safety.
      Hope this answers your question. Thanks :)

    • @lacertezzadellapena
      @lacertezzadellapena 2 роки тому +3

      @@procademy it does, thank you for clarifying! This course is so well thought! Thank you for your help

  • @GnorL
    @GnorL Рік тому +1

    unable to get the value in the parent component through $event, help me

  • @neuroscience5024
    @neuroscience5024 6 місяців тому

    I bought the most popular Angular course on Udemy 2 months ago but now I feel like I wasted my time on that course.
    Wow man. You are amazing. Such nice and simple explanations of concepts. Hats off to you. You are an amazing teacher.
    Thank you very much for creating such an amazing course.

  • @ezzybrezzy-xl3wd
    @ezzybrezzy-xl3wd Рік тому +1

    Hello sir I have a doubt here @21:11 if I select free in the radio button and my 2nd condition in the ngIf is true, how can the HTML understand and pick only the free courses and display it?

    • @rickyarya7673
      @rickyarya7673 Рік тому +4

      Consider this as if statement inside a for loop. And the output will be shown based on the if condition.
      Basically what happens is for loop will run for each element in the array and, if statement will check for each element whether it satisfy the condition or not. If the condition is true than it will print that particular course object.

    • @ezzybrezzy-xl3wd
      @ezzybrezzy-xl3wd Рік тому

      @@rickyarya7673 Thank you

  • @lacertezzadellapena
    @lacertezzadellapena 2 роки тому +1

    It works!!! Thank you so much!

  • @GouravKumar-fo1jo
    @GouravKumar-fo1jo Рік тому +1

    Worth watching sir

  • @DanEllis
    @DanEllis 2 роки тому

    You don't need the trailing slashes on your input elements. That was required for XHTML to keep the document well-balanced. It has no meaning in HTML 5.

  • @sachinvarghese2223
    @sachinvarghese2223 Рік тому

    I think (ngModelChange) is better than (change) , so that less code is needed

  • @PratikP-j1f
    @PratikP-j1f Рік тому +2

    Man o man you are Jwell ! what a beautiful series that too free of cost however I believe I am obliged to pay you, consider it encouragement for making more such videos ! Please send me Your UPI ID, I would love to contribute RS 500

    • @above___
      @above___ Рік тому +1

      UA-cam has a "thanks" button you can use that to give money 😄

  • @HealthChampion
    @HealthChampion 8 місяців тому

    You are awesome. :)

  • @devadharshinib8070
    @devadharshinib8070 2 роки тому

    Nice Explanation , Thank you sir

  • @ZainJahangir-oq5hy
    @ZainJahangir-oq5hy Рік тому

    excellent course

  • @helpinghands6475
    @helpinghands6475 Рік тому

    World best course

  • @theegalasuryamanoj4492
    @theegalasuryamanoj4492 2 роки тому

    please share git hub link

    • @procademy
      @procademy  2 роки тому +2

      github.com/manojjha86/complete-angular-13-course

  • @sivaprasad10410
    @sivaprasad10410 2 роки тому

    can u share json file pf this project

  • @AnkitSingh-sy6sb
    @AnkitSingh-sy6sb 2 роки тому

    Hi Sir, I did follow your code but my filter radio buttons are not working only all courses button is working, If I'm clicking on free courses and premium courses I'm getting blank page. Please help !!

    • @procademy
      @procademy  2 роки тому +1

      Have you made sure that the case of your value attributes of radio button matches the case you have specified in ngIf?? I suspect that might be the problem

    • @Алексей-ж4з8и
      @Алексей-ж4з8и Рік тому

      @@procademy i have the same problem because i code "course.type" with quotes. When i remove quotes, all working.

  • @Macrumik500
    @Macrumik500 Рік тому

    Your teaching skill is good but you have bad habit of repeating same thing again and again and do irritate most of the time. Just try to watch your own video after recording and before uploading.

    • @salsal-dd1dq
      @salsal-dd1dq Рік тому +9

      sometimes he's repeating to make sure that the audience got his point. The video is not made for you only, and instead of complaining, you can always skip