#26 Understanding Input Decorator | Angular Components & Directives | A Complete Angular Course

Поделиться
HTML-код
  • Опубликовано: 27 ноя 2024

Комментарии • 13

  • @marcotorres899
    @marcotorres899 Год назад +5

    I appreciate your way of teaching. This is amazing and I am starting to understand these concepts that I once thought would be impossible to wrap my head around. Thank you for that!

  • @danegordonpodcast3293
    @danegordonpodcast3293 Год назад +2

    dude thank you ive been trying to learn angular for months and your class is bye far the best class great explanations and examples seriously thank you, ive sat through hours and hours of angular courses that i could never understand

    • @peachess3284
      @peachess3284 9 месяцев назад +1

      He has a natural talent for teaching!

  • @SirFrancisFoley
    @SirFrancisFoley Год назад +3

    A simpler way to compute totalProductOutOfStock = totalProductCount - totalProductInStock but the method used is of value because it teaches people how to use the filter() method.

  • @jeetsingh6196
    @jeetsingh6196 4 месяца назад

    Nicely explained

  • @El_Bald
    @El_Bald Год назад

    Thank you sir for this series

  • @MuhammadUsman-ok5vs
    @MuhammadUsman-ok5vs Год назад

    Awesome explanation.....

  • @mostafaaljamal-u1w
    @mostafaaljamal-u1w Год назад +3

    plz, if you can call an api for the product item

  • @SimonChikezie
    @SimonChikezie Год назад +2

    Quick question why do we necessarily need to use @input and @output instead of doing all the logic in that very component

    • @Fr0z3nRebel
      @Fr0z3nRebel Год назад +3

      The filter component doesn't have access to the data in the product-list component unless we pass that date in explicitly. This is called encapsulation and is an important security benefit. I recommend reading up on encapsulation for more information.

    • @VGBNDGRL
      @VGBNDGRL 7 месяцев назад

      Like the first reply mentioned, it's important to modularize your code. keeping the filter component separate allows us to encapsulate an object's properties. Apart from security purposes, a fundamental objective of Object-Oriented programming is to reuse objects where we can. If we built that filter component within the product-list, we might not be able to use it in other components. This helps make the code reusable as well :)
      I recommend going through an OOP course online to supplement your Angular learnings, as you will slowly understand the pros and cons of different languages and frameworks on your own.