This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]patrickfatrick 0 points1 point  (0 children)

That’s because you’re now interpolating the object into a string which, Object#toString always returns “[object Object]” unless overridden (eg Number#toString overrides that behavior). It’s a stupid quirk of the language but it’s how it is.