What is this JavaScript syntax: {Ci, CC}? [duplicate]

This is called destructuring assignment. It is a feature of JavaScript 1.7, where in this context “JavaScript” refers to Mozilla’s specific extensions to the ECMAScript standard.

It is slated for inclusion in the next version of JavaScript.

The equivalent ECMAScript 5 code would be

var __temp = require('chrome');
var Cc = __temp.Cc;
var Ci = __temp.Ci;

Leave a Comment