Angular Signal Input - The Solution to Angular Inputs

Поделиться
HTML-код
  • Опубликовано: 28 фев 2024
  • Learn Angular signal input and how it simplifies getting data in the component. It solves major problems like using NgOnChanges and not specifying default value.
    ► CHECK MY COURSES - monsterlessons-academy.com/co...
    MOST POPULAR COURSES
    ► Javascript interview questions - monsterlessons-academy.com/co...
    ► Typescript interview questions - monsterlessons-academy.com/co...
    ► React interview questions - monsterlessons-academy.com/co...
    ► Angular Interview Questions monsterlessons-academy.com/co...
    ► Building real project with Angular + NgRx - monsterlessons-academy.com/co...
    ► Building real NestJS API - monsterlessons-academy.com/co...
    ► Building real fullstack project - monsterlessons-academy.com/co...
    ► Mastering Git - monsterlessons-academy.com/co...
    ► Mastering Docker and Docker Compose - monsterlessons-academy.com/co...
    FOLLOW ME
    ► TWITTER - / monster_lessons
    ► INSTAGRAM - / monsterlessonsacademy
    ► TIKTOK - / monsterlessonsacademy
    REFERENCES
    ► Source code - github.com/monsterlessonsacad...

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

  • @deanhantzis9630
    @deanhantzis9630 3 месяца назад +2

    Couldn't be explained better. Thanks.

  • @user-jh4yb1sk9d
    @user-jh4yb1sk9d 3 месяца назад +2

    Very useful. Thank you a lot

  • @amitsinha5260
    @amitsinha5260 3 месяца назад

    Really great and useful video

  • @mariusboianciuc7324
    @mariusboianciuc7324 3 месяца назад

    Thank you for your great work! But what do you think, is it ok to only use signals from now on? Or just in cases when we expect the variable to change ? how well optimized are they ?

    • @MonsterlessonsAcademy
      @MonsterlessonsAcademy  3 месяца назад +2

      They are stable and fast. Effect is still in dev preview btw. I don't see why not

  • @hamza201183
    @hamza201183 3 месяца назад

    Many thanks! Very informative :) Is this already in Angular 17? Or 17.1?

  • @ryanbutterworth26
    @ryanbutterworth26 3 месяца назад

    Thanks for this. I want to try and change a form builder to rather use signal inputs.The issue is in the test, even if I type the input correctly, the test gives an error. I tried with a simple number example.
    questionNumber = input.required()
    in the test
    describe('Question input', ()=> {
    it('should take in a input of type number', () => {
    component.questionNumber = 5
    })
    })
    I think it throwing an error, as you mentioned this is a ready only signal. Not sure how you would test it then?

    • @MonsterlessonsAcademy
      @MonsterlessonsAcademy  3 месяца назад +1

      I didn't use signals with forms. I don't think it will work or that forms are prepared to be used with signals. I would just leave forms as reactive for now.

  • @burningtree878
    @burningtree878 3 месяца назад

    Signals are awesome guys! Jump on the fun wagon and start programming naturally again 🎉

  • @maciek77killer
    @maciek77killer 3 месяца назад

    Can I use signal input in my dump component when in smart component I use observable with async? is it ok?

  • @user-ep2vn2wb5m
    @user-ep2vn2wb5m 3 месяца назад

    Thanks, very usefull.
    Angular team has really worked hard for this version but it seems to have neglected the SSR mode with the problem of accessing cookies from the server. This is a major problem of this version and remains unresolved since November. Unable to implement authentication on SSR. Do you have an alternative to this problem ?

    • @MonsterlessonsAcademy
      @MonsterlessonsAcademy  3 месяца назад +1

      Unfortunately no. I rarely use SSR for client projects

    • @user-ep2vn2wb5m
      @user-ep2vn2wb5m 3 месяца назад

      ​@@MonsterlessonsAcademy Whatever version, Angular always takes a crazy long time before the first client rendering. I tried several optimizations without success, that's why I turned to the SSR

  • @dg-cg5gi
    @dg-cg5gi 2 месяца назад

    I try this but it doesn't work. whenever I change my @inputs to input signals, the template in my child component doesn't like the syntax? As if it doesn't recognize it right?
    parent.component:
    child.component:
    objectArray = input();
    This fails in the parent component template saying: Property objectArray is not provided by any applicable directives nor by element?
    I can't find anything on this?

  • @botondvasvari5758
    @botondvasvari5758 3 месяца назад

    angular rocks

  • @omjagtap3432
    @omjagtap3432 3 месяца назад

    Is DSA important in finding the job as a full stack developer