About 50 results
Open links in new tab
  1. How do you use the ? : (conditional) operator in JavaScript?

    Jun 7, 2011 · What is the ?: (question mark and colon operator aka. conditional or "ternary") operator and how can I use it?

  2. syntax - Question mark and colon in JavaScript - Stack Overflow

    Question mark and colon in JavaScript [duplicate] Asked 16 years, 3 months ago Modified 4 years, 2 months ago Viewed 232k times

  3. When should I use ?? (nullish coalescing) vs || (logical OR)?

    The nullish coalescing operator (??) in JavaScript only considers null or undefined as "nullish" values. If the left-hand side is any other value, even falsy values like "" (empty string), 0, or false, it will not use …

  4. What does the "?" (question mark) mean in javascript?

    9 This question already has answers here: Question mark and colon in JavaScript [duplicate] (8 answers)

  5. Question mark after parameter as in obj.val?.prop [duplicate]

    Sep 3, 2020 · This is called Optional Chaining in JavaScript. It allows to drill down on objects without raising null exception. Eg: Try running the below code snippet, then uncomment the line and run it to …

  6. Javascript question mark operator, multiple question marks

    Jul 25, 2024 · Javascript question mark operator, multiple question marks Asked 1 year, 7 months ago Modified 1 year, 7 months ago Viewed 83 times

  7. conditional operator - What is " (…) ? (…) : (…)" notation (three ...

    Jun 24, 2024 · possible duplicate of javascript if alternative – Greg Hewgill Jul 23, 2010 at 22:03 possible duplicate of Question mark in JavaScript – Bergi Jul 30, 2013 at 16:18

  8. Is there a "null coalescing" operator in JavaScript?

    Jan 25, 2009 · Since Justin Johnson's comment has so many votes, and since double question mark vs && in javascript was marked a duplicate of this one, it makes sense to include && in an answer. First …

  9. What is the meaning of the question mark in javascript - but it is not ...

    Aug 3, 2021 · What is the meaning of the question mark in javascript - but it is not a ternary operator? [duplicate] Asked 4 years, 6 months ago Modified 4 years, 6 months ago Viewed 5k times

  10. javascript - Question mark statement with semicolon, do multiple …

    Sep 27, 2021 · Question mark statement with semicolon, do multiple things if true Asked 4 years, 4 months ago Modified 4 years, 4 months ago Viewed 889 times