|
|
|
|
|
by mediumdeviation
912 days ago
|
|
Actually that only works with Map. For plain objects the key is always the stringified cast of the key. > o = { [{}]: 1 }
{ '[object Object]': 1 }
> k = { toString() { return 'a' } }
{ toString: [Function: toString] }
> o = { [k]: 1 }
{ a: 1 }
|
|