Chapter 11
Writing Asynchronous JavaScript
IN THIS CHAPTER
Multitasking with Asynchronous JavaScript
Making promises you can keep
Putting it all together with AJAX
Fetching data
Simplifying promises with async and await
Understanding CORS
Working with JSON
“Your mind will answer most questions if you learn to relax and wait for the answer.”
—WILLIAM S. BURROUGHS
There's no getting around the fact that everything a computer program does takes time. Some actions, like declaring a variable or performing a simple calculation, take such a small amount of time that the action seems instantaneous. But when programs start to involve network requests, database access, and accessing resources outside of the web browser, wait times can start to add up.
Understanding Asynchronous JavaScript ...
Get JavaScript All-in-One For Dummies now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.