The Story of Asynchronous JavaScript

Поділитися
Вставка
  • Опубліковано 27 вер 2024
  • This is the story of callbacks, promises, and Async/await in JavaScript.

КОМЕНТАРІ • 463

  • @t3dotgg
    @t3dotgg 2 роки тому +386

    Really pushing the bar for programming content man. Thank you for these efforts. So hyped for the next generation of engineers who get to grow up with stuff like this 🙏

    • @uidotdev
      @uidotdev  2 роки тому +13

      ❤️

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

      Dying from possibilities and amount of things to learn but we are crawling up 😂

  • @aquilazyy1125
    @aquilazyy1125 2 роки тому +23

    The phone number vs. buzzer analogy is the best explanation I’ve ever seen on this topic

  • @hansmeyer2
    @hansmeyer2 2 роки тому +123

    The first time I witnessed AJAX in action was on the Microsoft Developer Network web site circa 2000. It was being used to dynamically load expanded nodes in the table of contents. I remember calling over other devs to show them and we were all trying to wrap our heads around this sorcery. What a low key way to introduce such a revolutionary thing.

    • @uidotdev
      @uidotdev  2 роки тому +18

      Had to be one of the earliest use cases. Great story. Thanks for sharing!

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

      @@uidotdev Before that, IE 5.0 had the original implementation in MSXML, late 1990s.

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

      @@robslaney3729 I remember that. Data islands. IE supported tag that would be loaded with (surprise) xml

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

      It seemed a little disingenuous that the Google executive talk about Gmail as maybe the first AJAX application when it was invented by Microsoft. Also I remember Google Maps rather than Gmail being the AJAX app that got everyone’s attention around 2004.

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

      @@MarcStober Finding high quality clips from that era is difficult. So it's less "who do I give credit to" and more "who has a useful clip that fits the narrative".

  • @frankfu1122
    @frankfu1122 3 місяці тому +3

    Wow that buzzer/phone example was a stellar analogy for promise/callback

    • @uidotdev
      @uidotdev  3 місяці тому +1

      Thank you! Glad it was helpful.

  • @pavfrang
    @pavfrang 2 роки тому +26

    This is one of the cases where C# was revolutionary. C# brought the async/await pattern (in 2012) almost 5 years before JavaScript implemented it (in 2017).

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

      problem is the single threaded event loop of JS makes the behavior wildly different between C# and JS.

    • @chadselph3076
      @chadselph3076 7 місяців тому

      Nah, F# had it in 2007; but it's really just a specialization of the do-notation in Haskell which has been around since 1998

  • @terencetuhinanshu
    @terencetuhinanshu 2 роки тому +42

    I love the historical context presented in such a succinct way. Will definitely point all junior devs I come by to these videos to get their bearings on how we got here.

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

      Means a lot. Thanks Terence!

    • @KalleJillheden
      @KalleJillheden 2 роки тому +5

      For additional historical context, referencing C# is good for paying respect to the language authors. They invented the async/await pattern and since then all languages have followed. It's truly a masterful pattern that joins together synchronous and asynchronous code

    • @flying-sheep
      @flying-sheep 2 роки тому +1

      @@KalleJillheden JavaScript has always been a bit more … amateurish than others. E.g its Promise class has problems (e.g. cancelling is not part of the API), and having map/reduce as array functions is also silly (having them on the iterator would be easier to JIT compile and also enable using them without having to convert some array-like thing like a NodeList into an array first: `document.querySelectorAll(...).iter().map(...).filter(...).toArray()` ).

  • @fyriss_
    @fyriss_ 2 роки тому +97

    these videos are one of the best on the whole platform, can't wait for more. It's especially great for young devs, who don't know context of some things in the past that well.

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

      Thanks so much. Means a lot.

  • @jaykelly1729
    @jaykelly1729 2 роки тому +50

    I get so confused learning JS man. Async is crazy for me rn… When I started digging in to async await a couple weeks ago I somehow found myself putting callbacks in my .then() functions. The other day I was writing Promise constructors inside async functions then trying to await them 😭😭
    Learning JS I’ve found it’s less about syntax and more about concept. Knowing what you need and where. Videos like this help me organize these concepts so no matter the syntax I can always keep myself oriented in the code.
    For example, my end goal while learning async Js is to be able to refactor code from callbacks to async/await. Not through memorized syntax, but because I understand that success, failure callbacks turn in to resolve(), reject() and that the callback functions are turned to thenables. Same with going from Promise constructors to async/await.
    Sorry for long comment I’m an aspiring dev with no one to talk to about this stuff. Also if I said anything wrong please correct me. I need knowledge lol.

    • @uidotdev
      @uidotdev  2 роки тому +9

      Couldn't agree more. It helps if you try to understand the bigger "Why" before you dive into the details of the syntax. Sounds like you've figured that out.

    • @HandledToaster2
      @HandledToaster2 2 роки тому +13

      Hey friend. Keep up the good work! I wish you the best :)

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

      "my end goal while learning async Js is to be able to refactor code from callbacks to async/await." I had a good chuckle at that -- since I was doing exactly the same thing. ;o) I've been meaning to get back to that (hence the reason I'm watching the video). I got sidetracked with other goals, and it's always a struggle in finding that balance between how far you go to try to "make up for lost time" and moving on to newer things like JS frameworks (but still practicing vanilla JS in parallel).
      For example: I'm starting a 20-week React bootcamp today. I thought about taking it last year, but I just felt I wasn't ready (and I was still deciding whether to go with Angular or React). But over the last year, I worked on things like calculators and populating grid & filtering a table. Filtering by a field is easy -- but filtering by a combination of fields, lists, option groups, etc. -- is something else entirely. Granted, you could use a 3-party grid to eliminate the hassle, but the "hassle" is the whole point -- to make it as complex as possible as a learning tool.
      I've got a glitch or two to fix, and then I'm gonna polish it up -- but the essence of it all works. That personal project just happens to be COVID data using the link below. I'm not making commentary on COVID one way or the other -- it's just data that provides a real-life example for filtering: coronavirus-19-api.herokuapp.com/countries
      Anyway, if you're interested -- I have plenty of advice to pass along if you have some questions and would like some suggestions & resources for your learning approach. And since I'm trying to keep my JS goals moving along in parallel with others, helping someone out would help me as well (especially since you're focused on something of great interest to me). And once I get this grid cleaned up fully-code commented, you're welcome to fork it from github if you like (same goes for the calculator).
      Oh, and I still haven't made up my mind on Angular vs React -- I need more experience to make up my mind (and even then, I'll keep the door open). As a learning tool to help out in a job I had where they were using AngularJS and ASP.NET MVC, I developed a personal application using those platforms (with the goal of migrating to Angular later). But I'm no longer at that company because I chewed out my manager for his sloppy work, poor customer service, and turbo-charged ego. Other than that, he was a great guy who taught me a lot. Unfortunately, he wasn't so keen on listening to others.
      Anyhoo, for various reasons -- I opted to go the React direction for now (with the aim of returning to Angular later so I can compare). And the bootcamp is a way to keep me on track (same goes for offering my help to you).
      For example: In preparing for that bootcamp, I bought a $39 course -- but instead of simply trying to plow through it, I paused after a couple of sections to practice what I've learned. I found these exercises that have been ideal for that purpose:
      coderfiles.dev/blog/reactjs-coding-exercises/
      I'm not suggesting you start doing React (or any framework) right now -- just giving you some ideas for how you approach your goals.

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

      Old Async code drives me crazy bro lol. I'm still trying to wrap my head around it.

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

      tbh before this video I had the opposite and wrong idea of async await. Async+await is forcing the execution to behave synchronously i.e. one after the other. All that and without blocking the whole browser. I guess the keywords turned out to be a bit misleading for me till now.

  • @KevinVandyTech
    @KevinVandyTech 2 роки тому +223

    I've used all of these patterns at some point in the past, but never fully understood the pros and cons of each pattern. Your videos are always the most clear explanations. Thank you

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

      Thank you Kevin! Glad it was helpful.

    • @cool_christian92
      @cool_christian92 2 роки тому +5

      I totally agree with Kevin! As a Java developer leaning more on JavaScript these days, this video and especially the concept of Inversion of Control and the way you present code we’re done excellently.

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

      It is somehow heartwarming seeing an experienced dev saying that he could not understand something meanwhile i'm hitting myself everytime I can't wrap my head around

  • @adityakachroo
    @adityakachroo 2 роки тому +15

    This is the best explanation of async/await. I always struggled in understanding it fully. Thanks for this amazing informative video

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

      Glad it was helpful!

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

    Holy crap, this was the clearest, most concise explanation I've found for this topic. 10/10.

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

      So glad it was helpful. Thanks for watching!

  • @francis_n
    @francis_n 2 роки тому +25

    I'm pretty confident with async Javascript but this was a great history and refresher. Well explained Tyler!

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

      Thank you Francis! Glad you enjoyed it.

  • @benjinguyen9965
    @benjinguyen9965 2 роки тому +41

    Damn man, you deserve yourself a hard-earned sub. Really appreciate the effort you put into these details which provides the perfect amount of detail. You're the "programmer historian" channel I've been looking for.

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

      Thank so much Benji!

  • @uwagideon2723
    @uwagideon2723 2 роки тому +13

    you always deliver awesome content

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

    Haven't seriously done web dev in 13 years and let me tell you, it's a completely different ball game now. I barely recognize JavaScript along with my outdated HTML and CSS. I don't miss it though, it was a horrible mess before and Internet Explorer 6 is no longer anyone's worry. Good job to everyone involved in pushing the technology further and thank you for this brief summary of something big that I missed.

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

    More of these docs! As a web dev cutting my teeth in the modern era, where most things are abstracted away from you, context of where these technologies came from is invaluable.

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

    These are some high quality videos, happy the algorithm recommended this channel

  • @SuboptimalEng
    @SuboptimalEng 2 роки тому +9

    JS Dev: Call me back when you get the chance
    Date: No promises

  • @cinnanyan
    @cinnanyan 2 роки тому +13

    The one thing that JavaScript is still missing natively is the ability to handle asynchronous streams of data, which means an external library like RxJS is needed to make doing this manageable.

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

      The RxJS people have been in full force in the comments 😅

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

      could you state an example for handling asynchronous streams of data?

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

      ​@@pizzapanni WebSocket connections

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

      @@cinnanyan look at for await you can use that with a generator that is fed by the websocket messages.

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

    This channel will blow up. Glad I found you early. Exceptional information and love your point of view on this kind of stuff.

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

      Thank you so much for the kind words ❤️

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

    I adore the story telling and the occasional memes. Almost everything that's new is built upon something existing and I absolutely love the fact that you provide the whole journey of a feature, that context helps clear the abstraction with a lot of new tech that we just use without really understanding the depths of it and why should we use it.

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

      So glad it was helpful. Thanks for watching!

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

    why is more important to me when learning new things and thanks for this.

  • @flow7502
    @flow7502 2 роки тому +11

    I'm learning JS at the moment, only getting started with the async part of it. And this is just the video I needed. Everything makes so much more sense. Thanks a lot for this. Liked and subbed.

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

      Glad it was helpful!

  • @square-pixel
    @square-pixel 2 роки тому +2

    Fun video. One point I’d add is that async/await is built on-top of the same Promise API. Every async function returns a promise; and likewise, await operates on a promise. It’s actually possible to implement async/await-like behavior using generator functions and some glue logic to connect the Promise API-making async/await a kind of syntactic sugar.

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

      That’s sort of how Python does it. Promises/futures and the event loop are just part of the standard library (asyncio), implementable in pure Python, rather than being part of the core language.

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

    this is the best channel I've came across , thank you god 💘

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

      Thanks for watching!

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

    This is the most incredibly entertaining programming video I've ever seen

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

      Glad you enjoyed it!

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

    That's the best video on promises I have seen so far

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

    The simplicity and depth of these tutorials are second to none.
    Congratulations on the channel!

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

    This is a phenomenal "Tutorial" history lesson!

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

      So glad you enjoyed it!

  • @benoitleger-derville6986
    @benoitleger-derville6986 2 роки тому +2

    🟡Wonderful hindsight and clear vision of technological advances.

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

    For a guy who learned JS only from Async / Await - this is fucking amazing!

  • @sleros7773
    @sleros7773 2 роки тому +6

    Great video! Always great to learn how one tool came to existence and what is the reason behind its existence.

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

    100 for creativity , and 100 for content , thank you

  • @TheBicPen
    @TheBicPen 2 роки тому +5

    Nice video! JS has a reputation for having many weird quirks, but this video just shows that with a great team behind it, a language can improve and fix some of the problems of past design. Can't wait to see what other features will be added in the future!

  • @HarryLowtonIT
    @HarryLowtonIT 2 роки тому +23

    Another awesome video! Can really tell the incredible amount of time you put into this episode🔥
    my main question to myself after watching was should I go to Denny’s? 🥞🍳

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

      Thank you Harry! My only goal in life is to get restaurants to sponsor me for these. Imagine the possibilities.

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

      @@uidotdev I fully support your life goals!

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

    i already used this in my capstone project and because of that i graduated BSIT college
    now im continue to learn

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

    This is the best explanation of asynchronous code I've ever seen!

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

    Fireship style loving it!

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

      Jeff is the 🐐

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

    The restaurant analogy is helpful for understanding inversion of control. Thanks.

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

    This is a brilliant video, uidotdev. Great job mate.

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

      Thank you! Means a lot.

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

    Oi, where was this 3 years ago when I needed it 😭

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

      Thanks for watching!

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

    Fantastic video! Great examples that you provide along the way, very easy to follow and grasp while you at the same time maintain a good pace.
    Already looking forward to your next video! :)

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

      Thanks for watching!

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

    Outstanding man. THIS is the type of coding content I've been looking for. Absolutely destroying the like button on this one.

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

    I'm so glad I found this channel!

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

    This video just showed up in my timeline and even though I was fairly certain I'd know all the information, but I clicked on it anyway because I'm always curious to hear what "new" voices are saying in the dev community. I was very impressed with the video production and the concise and precise explanations and thought to myself, "who is this guy." I then saw the "tylermcginnis" in the getuser example, and thought "ah yes, this all checks out."
    Keep making stuff Tyler! You've already had a massively positive impact on my career growth as a SWE, and I'm excited to see you're now on UA-cam, making your content more broadly accessible to the wider community! 👍

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

      I always love comments like these. Thank you so much for all the support throughout the years. Glad I could be helpful! ❤️

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

      wasn't the first version of Outlook for the Web - a XHR dynamic desktop app like site?

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

    I have never thought of Promises as eliminating inversion of control, pretty cool detail!

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

    This was a damn good visual and conceptual analogy of Promises. Hats off to you sir.

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

    This is awesome! Defo saving this for later.

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

    First time I hear a valid argument for async/await over .then() / .catch()... Thank you!

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

      Glad you enjoyed it!

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

      I don't know... Why don't catch errors where it occured? The gigantic catch block where all exceptions fall in, and you don't know what caused the problem never made sense to me...

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

      @@gabiold You can still use .catch on individual await calls if you want (since they return a promise).

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

      @@uidotdev Ye, but what's the point then... Await takes away the async nature of the calls and blocks instead. It's not an evolved way to write code, just a possibility to avoid dealing with Promises if we don't need asynchronity.
      Prqctically it just turns a Promise into a function call as if it were ended with a
      while (!completed) continue;
      wait loop.
      If you really need asynchronity in the callee, you still have to write .then() calls.

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

      ...and catching the error in the Promise in the first await will not trigger a higher level try/catch block, so it will not jump out of the execution of the block and continues with the second await call.
      This is usually not what one wants, when the calls depend on each other.
      In my opinion the .then() syntax does not decrase readability making harder to follow. Rather the opposite: it clearly signifies dependency, it is seen when something will be executed in the chain, you can see that there is a dependency chain even, not just a series of function calls below each other.

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

    Love this style of video, really helps get the context and a better understanding of the reason behind different kind of implementations. Hopefully you will continue this series.

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

      Glad you enjoyed it!

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

    Amazing video man! I can't believe I've been missing such great content. Thank you 🙏🏾🙏🏾

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

      So glad you enjoyed it!

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

    another banger from uidotdev

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

    This is actually interesting not just for js but super well made,
    Thanks. So good that I’m watching again to absorb

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

    This is a gem.

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

    Extremely clear explanations, subscribed !

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

    Wish I had this video a few months ago when I was first really trying to learn about promised and async await functions in JavaScript. This video explained everything I miss understood and had to trial an error to get, as well as neatly condensed everything I did understand from probably 5-10 videos of much longer length. Can’t wait to see more content from you and definitely plan to check out your other videos

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

      So glad it was helpful!

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

    I'm a backend dev only learning about these amazing and powerful tools. It's pretty great

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

      Glad you enjoyed it!

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

    Simply remarkable! 😍

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

      Thanks for watching!

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

    Simply amazing!

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

    Loving this series!

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

      Thanks for watching!

  • @ЂорђеЈеленковић
    @ЂорђеЈеленковић 2 роки тому +4

    Great video like always, give us some more! :)

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

    this is the best explanation out there 💯👌

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

    9:07 The issue isn’t the difficulty of adding new features to JavaScript, it has more to do with the overhead of those features. Here we want to add a coroutine feature. The traditional way coroutines were implemented allows preemption to occur inside any function call. This means each coroutine “thread” needs its own full stack, just like you have with multithreading. This is called “stackful” coroutines.
    The way JavaScript, Python and other languages do it, with the async/await keywords, is called “stackless”. What that really means is, because preemption can only occur on explicit “await” calls, and these are only allowed in the bodies of “async” functions, only a small amount of stack data needs to be switched when preemption happens.

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

    Promise.all() is still very useful and can be more convenient and robust than async-await

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

    Man those examples are amazing.... very clear...

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

      Thanks for watching!

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

    Such a phenomenal channel! Keep up the great work...

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

    your videos are amazing and professional, it's a shame that some newer generation of "programmers" are learning e.g. react without even understanding fundamentals. i hope your channel get a lot more attention.

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

    You deserve my subscription for this!!

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

    Promises are just Tasks from the .Net Task Parallel Library, and async/await are from C#, utilizing them the same way. Microsoft was on the committee, obviously. ;)

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

    Fantastic work

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

    love the content

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

    I always found promise to be a freaking mess, and I was always like "bruh, why don't just do async/await already, duuuuh." hehe they finally got the message :p

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

      Thanks for watching!

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

    👨‍💻👌 awesome video bro

  • @Sam-qn4ly
    @Sam-qn4ly 2 роки тому +2

    Great vid! So smooth.

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

      Thanks for watching!

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

    Great video. Super easy to follow and very informative while also being engaging.

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

    keeping making this kind of videos and also try to make another kind of videos too. So that I dont get bored.

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

    I like these types of videos! More please! Subbed! Adblock disabled! 😁

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

    Awesome video, thanks!

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

    Excellent explanation!

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

      Thanks for watching!

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

    Amazing!

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

    0:08 Remember, everyone was a beginner once ☺

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

    Amazing content, informative as well as entertaining. Your analogies are on point.

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

      Much appreciated!

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

    Damn man, you are amazing!

  • @BrunoOliveira-tj5xw
    @BrunoOliveira-tj5xw Рік тому

    Great vídeo! Saved as part of my theory material. Subscribed

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

    The explanation is beautiful, you've earned a new sub 👍

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

    I got a wix ad right on the timing of "in 1999, everything changed"

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

    Keep it up! 😃

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

    Very well executed video! Keep up the good work. I just subscribed!

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

    amazing content

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

    amazing

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

    I really like using
    await new Promise(requestAnimationFrame);
    It works wonders.

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

    Keep posting more videos 😀

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

    4:33 thats a good one :D

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

      Thanks for watching!

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

    Nice Introduction !

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

    Thank you C# for async/await

  • @alexenax1109
    @alexenax1109 9 місяців тому

    Amazing content!

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

    if only i could use the beautiful simplicity of async/await and promises instead of the obnoxious complexity of observables and rxjs

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

      RxJs seems complicated at the start but once you grok it you will never reach for a promise again. RxJs really is the best UI technology to come out in years, you just need to start thinking reactively.

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

    Coming from a Haskell Background, this does remind me of Monads. The promise notation with .then() does work pretty much exactly, like the bind (>>=) operator works, and the async/await notation does seem like the JS version of the do-Notiation. Neet stuff.

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

      All roads lead to monads.

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

    These videos are on another level! I wonder how much time it takes per video to make it so slick?

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

      This one was 3 weeks of ~50 hour weeks.

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

      @@uidotdev 😲 Thanks a lot for taking all that pain for the quality content 🙌🏽
      I'm sticking with transition-less animations on my channel for now 🙈

  • @xenobino8432
    @xenobino8432 2 роки тому +6

    Another thing you didn't mention is promise joining. 2 functions return 2 promises and you want to chain them in one promise. There is the promise.all approach but it might not suit your need so you switch to returning a promise inside .then callbacks but now you recreated the callback hell with promises. If any of you who is reading my comment fell for this problem, the simplest solution I can think of is using await like the dude in the video did. DO NOT over promisify stuff, only use promises when you have a reason to make the task asynchronus. If you're a library developer, provide a "yourlib/promises" folder in your package that has the promisified version of your library

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

      Correct. It's hard to get the entire API into videos like this.