⊗jsPmCdBVC 118 of 504 menu

Conditions with boolean values in JavaScript

Suppose we have some variable that can take the values true or false:

let test = true;

Let's write if that tests our variable for the value true:

let test = true; if (test === true) { console.log('+++'); } else { console.log('---'); }

Check that the variable test is equal to true.

Check that the variable test is equal to false.

English
AfrikaansAzərbaycanБългарскиবাংলাБеларускаяČeštinaDanskDeutschΕλληνικάEspañolEestiSuomiFrançaisहिन्दीMagyarՀայերենIndonesiaItaliano日本語ქართულიҚазақ한국어КыргызчаLietuviųLatviešuМакедонскиMelayuမြန်မာNederlandsNorskPolskiPortuguêsRomânăРусскийසිංහලSlovenčinaSlovenščinaShqipСрпскиSrpskiSvenskaKiswahiliТоҷикӣไทยTürkmenTürkçeЎзбекOʻzbekTiếng Việt
We use cookies for website operation, analytics, and personalization. Data processing is carried out in accordance with the Privacy Policy.
accept all customize decline