4 ms·
Enclosing it within quotes seems like defeat. Edit: You can assign the property to be without quotes using a bit of a hack, you just can't call it. var o
by CatsoCatsoCatso 11y ago
Enclosing it within quotes seems like defeat.
Edit: You can assign the property to be without quotes using a bit of a hack, you just can't call it.
var o = {}; // Creates a new object
Object.defineProperty(o, "(╯°□°)╯︵┻━┻", {value : "Please respect tables! ┬─┬ノ(ಠ_ಠノ)"});
//=> o = {(╯°□°)╯︵┻━┻: "Please respect tables! ┬─┬ノ(ಠ_ಠノ)"}
Trying to call o.(╯°□°)╯︵┻━┻ returns an error though.