Angular Rxjs: Use Map Operator & Async Pipe

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

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

  • @florianuhlmann6478
    @florianuhlmann6478 2 года назад +7

    This video is awesome.
    The way from just solving the problem to senior clean code is awesome.
    Plus it has straight to the point explanation.
    more than awesome job

  • @MG-wx8yx
    @MG-wx8yx Год назад +1

    The best thing about this video is that instead of just showing us the best way to do it, you showed us the bad code first and move slowly from that to the best and cleanest way.

  • @mohomedrimnaz1234
    @mohomedrimnaz1234 Год назад +1

    Brilliant! Instead of showing us the "right" way, you showed us how we can improve our code. Just brilliant!

  • @theoklitosbampouris3975
    @theoklitosbampouris3975 3 года назад +5

    Another very very instructive video from Profanis! It can be applied in real world, if someone wants to do a code cleaning and refactoring, but even better to start with a clean component with only duty to represent the data via its template.

  • @azatfarmanyan150
    @azatfarmanyan150 Год назад +1

    Thanks for this awesome lesson

  • @JayTailor45
    @JayTailor45 3 года назад +2

    I like this way of having readable code. Thanks.
    Looking forward for more stuff. :D

  • @WahomeTheScientist
    @WahomeTheScientist Год назад +1

    Awesome tutorial. Really saved my time

  • @LondonStory945
    @LondonStory945 2 года назад +2

    Excellent tutorial, saved a lot of time. Thanks a lot!

  • @NuevaHD
    @NuevaHD 3 года назад +2

    thnx a lot , good job, from tunisia

    • @CodeShotsWithProfanis
      @CodeShotsWithProfanis  3 года назад +1

      Thanks a lot for your feedback. Greetings from sunny Greece :)

    • @NuevaHD
      @NuevaHD 3 года назад

      @@CodeShotsWithProfanis 🇹🇳 🇬🇷

  • @Instgate
    @Instgate 2 года назад +1

    Awesome!!! Great learning from you…

  • @janardhanangurusamy1658
    @janardhanangurusamy1658 Год назад +1

    Nice explanation 🎉

  • @sergiokagiema9658
    @sergiokagiema9658 3 года назад +2

    Excellent tutorial! Keep at the good work!

  • @lyubomyrkuzenko3188
    @lyubomyrkuzenko3188 3 года назад +2

    thanks for this video. next step to this content can be "Adapter pattern". And also angular patters it's a good idea for separate video list.

  • @crissanchez1251
    @crissanchez1251 2 года назад +1

    Excelent video, thanks

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

    Nice video, awesome, only one thing is missing in the whole video. If you could explain how to filter observable data by entering some value in input files and use the async pipe. This means filtering an observable data without a subscription.
    Hope I could helped in understanding.
    1. input field -> accepts user input.
    2. Observable data gets filtered and displayed on a browser with async pipe in html without any subscription in ts file.

  • @jaroslavbilek7361
    @jaroslavbilek7361 Год назад +1

    Very helpful!

  • @evanzhang9915
    @evanzhang9915 Год назад +1

    Step to step to refactor the code to align with the single responsibility design pattern!

  • @gururajmoger8649
    @gururajmoger8649 3 года назад +2

    Awasome.. could u pls explain if there is more dependent api and errors handling in the same pattern

  • @storiesbyemily4170
    @storiesbyemily4170 3 года назад +1

    I don't know, I personally love to have all data in one component, maybe something is wrong with me but clicking several files in order to change something is not really for me, I prefer to have everything together and scrolling up and down in order to change things.

    • @CodeShotsWithProfanis
      @CodeShotsWithProfanis  3 года назад +4

      In programming there are that many ways of doing a thing and each one of us picks what works best for us.
      The way of coding depends also on the scale of the project and team size. If for example you work on a small project with one developer, it's "okish" to have everything in one file.
      On the other hand, if you are on a big project with many team members, then having everything in one file will become very soon a DRY violation.

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

    Why could you not use partial there?

  • @trustingod0
    @trustingod0 2 года назад +1

    Great video. But at 4:34 I was confused about how you got the country response model code. Thank You !!!

    • @CodeShotsWithProfanis
      @CodeShotsWithProfanis  2 года назад

      The countriesService.get() method returns a hard-coded array of countries github.com/profanis/codeShotsWithProfanis/blob/13/rxjsMapAndAsyncPipe/src/app/countries.service.ts
      Since the response is an array, I use the JavaScript map function (line 14) to return a new array.
      I hope this answers your question

    • @trustingod0
      @trustingod0 2 года назад +1

      @@CodeShotsWithProfanis NO there must be a shortcut or something you selected because u selected a line of code then u went to the next line and then it showed the country response model properties. I could only see the country model properties. If you will go to that time in the video then you will see what i was referring to. I just want to know how to use the shortcut to switch between model properties. You used the country model then for CODE you switched to the country response model. I could only see properties for country model. How did you do that???????????? You need to tell me how to do this or otherwise i cannot see the code properties and am unable to run your example tutorial. Thanks !!!

    • @CodeShotsWithProfanis
      @CodeShotsWithProfanis  2 года назад +1

      ​@@trustingod0 I assume you mean the intelisence. The countriesService.get() method returns the type CountryResponseModel[] and this is the reason you can see all the properties.
      ruclips.net/video/sJjijzJw3ZQ/видео.html

    • @trustingod0
      @trustingod0 2 года назад +1

      @@CodeShotsWithProfanis Yes you are right. I am sorry my code was not correct and that was the reason why I was not seeing all of the properties of the CountryResponseModel. Thank You !!!! If I can ask a quick question I was wondering can you refer me to some articles or videos that can assist me with error handling as it relates to Observables. Thanks Again !!!!

    • @CodeShotsWithProfanis
      @CodeShotsWithProfanis  2 года назад +1

      @Ronald I do not have something in mind, but you gave me a great idea 💡 🤗
      I will create a video "error handling in rxjs". Thanks for your feedback

  • @BirukAssefa
    @BirukAssefa 3 года назад +1

    Thanks a lot you save my day

  • @emreaka3965
    @emreaka3965 2 года назад +2

    Thank you.

  • @ArjunRaj-xn8es
    @ArjunRaj-xn8es Год назад

    awesome 😍

  • @roman-tp6sd
    @roman-tp6sd 2 года назад +1

    Tnx!

  • @aaronmcmillan6379
    @aaronmcmillan6379 2 года назад

    You say it returns an array and you need to convert it, convert it to what mate