JS Built-ins
Symboldescriptionbeginner

Symbol.description β€” empty string

πŸ“– Usage Example
const s = Symbol('')
s.description            // β†’ ''
s.description === undefined  // β†’ false

An empty string is a valid description β€” distinct from having no description at all.

Symbol With Empty String Description

Passing an empty string '' gives a .description of '', which is different from undefined.

Challenge: Verify the empty string case.

πŸ’‘ Hints (1)
  • β€’ Empty string '' is a valid description β€” it is not the same as undefined.