Logical assignments
Widely available since 2023-03-16
The logical AND assignment (&&=
) and the logical OR assignment (||=
) operators short-circuit the respective binary logical operators.
Learning resources on MDN
Browser support
- Chrome 85 Released on 2020-08-25
- Chrome Android 85 Released on 2020-08-25
- Edge 85 Released on 2020-08-27
- Firefox 79 Released on 2020-07-28
- Firefox for Android 79 Released on 2020-07-28
- Safari 14 Released on 2020-09-16
- Safari on iOS 14 Released on 2020-09-16
Specifications
- ECMAScript Language Specification (#sec-assignment-operators), from TC39 (Ecma International).