Practical Destructuring with Promises and Array Methods

Sdílet
Vložit
  • čas přidán 4. 08. 2021
  • This tutorial explains how you can use array and object destructuring in conjunction with Array methods and Promise-based methods like fetch.
    Note: The rest operator must be the last argument when destructuring. The code sample linked to below has the correct syntax for doing this.
    Code from video: gist.github.com/prof3ssorSt3v...

Komentáře • 27

  • @jaganmohan9013
    @jaganmohan9013 Před 2 lety +2

    This channel deserves more subscribers for its quality content

  • @RHILL-hb1hr
    @RHILL-hb1hr Před rokem

    Your videos are so easy to understand. Thank you so much!

  • @sinsin7843
    @sinsin7843 Před 2 lety +1

    really like your tutorial !! even non-native English speaker still can understand , thank you~

  • @haroldtitcomb
    @haroldtitcomb Před 11 měsíci

    Man's a genius....simply put

  • @Self-taughtCoder
    @Self-taughtCoder Před 2 lety +1

    Oh my, I found a home where JS is understood. Waiting for that video that will touch on JEST, hoping that it is being thought of. This video has made me go back and refactor my code. Thanks a lot.

  • @allezzthepunk
    @allezzthepunk Před 2 lety +2

    Actually, I am going to use them now!

  • @pamphilemkp5841
    @pamphilemkp5841 Před rokem

    Thank you so much our senior dev , this video worth my time ❤

  • @krish_unni
    @krish_unni Před 2 lety

    Great sir. I m gonna use this. Thanks for the tutorial. Lots to learn from you.

  • @2ru2pacFan
    @2ru2pacFan Před rokem

    Thank you Professor! :)

  • @mickwhyte4204
    @mickwhyte4204 Před 2 lety

    Great tutorial! Thanks.

  • @micahelm3222
    @micahelm3222 Před rokem

    great video!

  • @dodokwak
    @dodokwak Před 2 lety +1

    Thank you.

  • @mubashirwaheed474
    @mubashirwaheed474 Před 2 lety +1

    Thanks

  • @cloudpuncher4615
    @cloudpuncher4615 Před 2 lety +1

    Thanks heaps for the great video, would it be possible to fold values from Promises using destructuring? I trying to compose multiple sync and async functions while keeping the runtime under 50ms (CF worker) but the new Promise creation with .then is killing performance.

    • @SteveGriffith-Prof3ssorSt3v3
      @SteveGriffith-Prof3ssorSt3v3  Před 2 lety

      It has to do with how JS deals with the event loop and tasks and microtasks.
      czcams.com/video/cCOL7MC4Pl0/video.html - this should help you visualize it.

  • @mohamedyoussef8835
    @mohamedyoussef8835 Před 2 lety

    Excellent +++++++++++++++++

  • @hammadahmad5383
    @hammadahmad5383 Před 2 lety +2

    Hi Sir 😊
    Thanks for this tutorial video. I have a request, please make a video teaching how to make an image slider using Javascript with autoplay 🙂. And one more thing, is there any css property for smoothing the text on the webpage becuase the text on my website is very distorted on the edges and it doesn't look nice.
    Thanks 😊

    • @SteveGriffith-Prof3ssorSt3v3
      @SteveGriffith-Prof3ssorSt3v3  Před 2 lety +1

      I made this tutorial a few years ago on building a carrousel / image slider - czcams.com/video/mEQl4mEex34/video.html
      and this about touch events
      czcams.com/video/ga_SLzsUdTY/video.html
      Please add any tutorial requests in the comments here - czcams.com/video/LCezax2uN3c/video.html

  • @johmcg64
    @johmcg64 Před 2 lety +1

    Thank you. When using destructuring, if I change the order of name and partner, will it still work?

    • @SteveGriffith-Prof3ssorSt3v3
      @SteveGriffith-Prof3ssorSt3v3  Před 2 lety +2

      For object destructuring you can use any order for the property names. For array destructuring it has to be in the numerical order.

    • @johmcg64
      @johmcg64 Před 2 lety +2

      @@SteveGriffith-Prof3ssorSt3v3 Tank you. That is magnificent.

  • @yadusolparterre
    @yadusolparterre Před 2 lety +1

    Why would you use a map() method without returning anything though... 🙄

    • @SteveGriffith-Prof3ssorSt3v3
      @SteveGriffith-Prof3ssorSt3v3  Před 2 lety +2

      Because it was the input into the map function that was being discussed, not what the map method does or returns.

  • @devT44
    @devT44 Před rokem

    At 7:55 what u have said is wrong, sir. Rest element must be last in a destructuring pattern.