Optional chaining is not the same as a logical and

The && chain it replaces short-circuits on every falsy value, and optional chaining stops only for null and undefined.

// stops on 0, '', false — which is usually a bug
const n = counts && counts.total;

// stops only on null/undefined
const n = counts?.total;

// it also works on calls and index access
const v = config?.get?.('key');
const first = rows?.[0];

The numeric field case is where the old pattern was reliably wrong, and it is silent — a total of zero became 0 either way, so nobody noticed until the value was an empty string somewhere else. The optional call form is subtler than it looks: it checks whether the property is nullish rather than whether it is callable, so a non-function value still throws. It cannot be used as an assignment target, which is the second thing people try.