ES6 Computed property names allow you to dynamically create property names using an expression in brackets ([ ]
) similar to
property accessors. Below, computed property names are demonstrated using Object Literals, ES6 Classes and ES6 Symbols.
This feature is available in Chrome 42 behind the
--harmony-computed-property-names
flag. For step-by-step instructions on how to use command-line flags with Chrome, read the
command-line flags
guide. In this case, you would launch Chrome with
--args --js-flags="--harmony-computed-property-names"
.