Synchronous Code
noun
say it: “SING-kruh-nus KOHD” /ˈsɪŋkrənəs koʊd/
Code that runs one line at a time, in order, with each line finishing before the next one starts.
What is Synchronous Code in JavaScript?
Synchronous Code — Code that runs in order, one line at a time: each line finishes before the next one starts. Most code is synchronous, and that's only a problem when one line takes a long time.
console.log('Take the order');
console.log('Make the pizza');
console.log('Hand it over');
// Take the order
// Make the pizza
// Hand it over
In a sentence
- “Reading three lines of synchronous code is like reading a recipe: step one, then step two, then step three.”
- “The receipt total printed last because synchronous code adds up every line before it moves on.”
Level: Apprentice · More JavaScript terms at this level
Updated