Think of a promise like a kitchen receipt: you do not have the result yet, but you have proof the work was accepted. While waiting it is pending. Later it becomes fulfilled (success) or rejected (failure). No network here — only delayed local work (Phase 10 timers).

State

Value / error

(none yet)

Timeline

Press a button.

Start a delayed promise and watch the state change.

Important JavaScript

// A Promise has one of three states:
// pending → fulfilled (with a value)
// pending → rejected (with a reason)

const later = new Promise(function (resolve, reject) {
  setTimeout(function () {
    resolve("Scout report ready");
    // or: reject(new Error("Timeout"));
  }, 800);
});

// later is pending right now — the value arrives later.