Hi everyone! I'm the author of code.mu :)
I'd love to chat with my non-Russian audience. I'm looking for your feedback on the site and the translation quality. Let's chat:)
⊗jsSpSyInr 51 of 294 menu
◀ ▶

Introduction to the Symbol type in JavaScript

The Symbol type is designed to create unique identifiers. These identifiers can be used to create unique object keys.

Let's create a symbol as an example:

let sym = Symbol(); console.log(sym);

You can create several symbols:

let sym1 = Symbol(); let sym2 = Symbol(); console.log(sym1, sym2);

The symbols we create will be unique. This means that when compared, they will not be equal:

let sym1 = Symbol(); let sym2 = Symbol(); console.log(sym1 === sym2); // false

Create several symbols.

← →
↑
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