~/talk

Debugging async JS

Talkat React Miami 2022 · 2022-04-18..04-19· [javascript]
slides:none on file

Walks through concrete failures: a callback-based getConfig returns undefined because readFile is async, a handmade Promise silences errors by not rejecting, a .catch placed too early still allows later .then to run, and refactoring to async/await accidentally serializes parallel requests or returns a Promise into UI. Uses console.log and Chrome DevTools to set breakpoints and step through, demonstrates fixes like always reject errors, move .catch to the bottom, and use debugger to step through and emphasizes experience as the best prevention.

AI-written summary · about

  1. 0:00Introduction
  2. 2:04Analyzing async functions
  3. 3:37Effective logging techniques
  4. 5:02Understanding async behavior
  5. 7:09Silent promise errors
  6. 8:39Promise debugging pitfalls
  7. 10:08Correcting error handling
  8. 12:01UI and async order
  9. 13:15Using the debugger
  10. 14:14Stepping through promises
  11. 16:17Async and await
  12. 17:13Blocking vs non-blocking
  13. 18:57Complex async bugs
  14. 20:12Building debug intuition
  15. 21:43Be the bad dog
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.