Why Symbol('test').toString()
works well, but I can't use '' + Symbol('test')
?
It will throw Error:
cannot convert a Symbol value to a string
Why does the implicit type conversion not work? Why is the code not equal to '' + Symbol('test').toString()
?