jQuery Deferred isResolved() Method

Beginner
5 min read
Updated: Nov 2026
3 examples
Deferred

Definition

deferred.isResolved() was a boolean check: true after resolve() / resolveWith(), otherwise false. It took no arguments. Today, use state() instead.

Syntax

Start with these common calls. Keep them short and readable.

jQuery
// OLD (jQuery 1.5–1.7 only — removed in 1.8)
dfd.isResolved()  → true | false

// MODERN replacement
dfd.state() === "resolved"

state(): "pending" | "resolved" | "rejected"
CallWhat it does
deferred.isResolved()Learn jQuery deferred.isResolved(): check if a Deferred was resolved, why it was removed, use state() === \

Load jQuery before your script (CDN or local file), then wrap DOM work in $(function () { ... }) when needed.

Parameters

ParameterDescription
Step 1Create or receive a Deferred / Promise.
Step 2Call dfd.state() at a checkpoint (after resolve, or inside done).
Step 3Compare with === "resolved" for the old isResolved() meaning.

Return Value

Return ValueDescription
See examplesCheck the examples below for what this API returns in common cases.

jQuery Examples

Example 1 — After resolve()

Once resolved, the modern check returns true.

jQuery
var dfd = $.Deferred();
dfd.resolve("Request successful");

var isResolved = dfd.state() === "resolved";
console.log(dfd.state());   // "resolved"
console.log(isResolved);   // true
Try It Yourself

How It Works

  1. Create a pending Deferred.
  2. Resolve with a value — state becomes "resolved".
  3. Compare state() === "resolved" (old isResolved()).

Example 2 — Still Pending

Before settle, the check is false.

jQuery
var dfd = $.Deferred();

console.log(dfd.state());                 // "pending"
console.log(dfd.state() === "resolved");  // false
Try It Yourself

How It Works

  1. Fresh Deferred starts as "pending".
  2. No resolve yet — nothing has succeeded.
  3. Check === "resolved" → false.

Example 3 — After reject()

Failure is not resolution — the check stays false.

jQuery
var dfd = $.Deferred();
dfd.reject("Network error");

console.log(dfd.state());                 // "rejected"
console.log(dfd.state() === "resolved");  // false
Try It Yourself

How It Works

  1. Reject settles as failure → "rejected".
  2. Resolved? No — state is locked to rejected.
  3. Compare still yields false.

Frequently Asked Questions

isResolved() returned true when the Deferred had been resolved (success path), and false while pending or after a rejection. It took no arguments.
No. It was deprecated in jQuery 1.7 and removed in 1.8. In current jQuery, use dfd.state() === "resolved" instead.
Call deferred.state(). It returns "pending", "resolved", or "rejected". Compare with === "resolved" for the old isResolved() meaning.
No. done() registers a callback for when resolution happens. isResolved() (and state()) are synchronous status checks — they do not listen for future resolves.
At known checkpoints — after resolve(), inside done(), or for debugging. Prefer done()/then() for reacting to success instead of polling.
No. Once settled, the state is locked. state() is "resolved" only after resolve()/resolveWith(), never after reject().

Next: deferred.isRejected() Method

Send progress updates while a Deferred is still pending.

deferred.isRejected() Method tutorial →

CODETOFUN NEWS

Stay Ahead in Tech

Get the latest IT news, programming updates, and technology trends directly on your phone.

Your daily dose of tech, straight to your feed.

About the author

Mari Selvan M P
Mari Selvan M P 🔗

Developer, cloud engineer, and technical writer

  • Experience 12 years building web and cloud systems
  • Focus Full Stack Development, AWS, and Developer Education

I write practical tutorials so students and working developers can learn by doing—from databases and APIs to deployment on AWS.

8 people found this page helpful