This is a way to provide polyfiling for IE browsers to use the console.table functionality that is given in modern web browsers such as Firefox and Chrome.
This allows us to view data in a table layout, takes . There is also an optional 'columns' parameter which takes the form of an array of strings similar to the Chrome console.table.
From the example given by Google Chrome:
function Person(firstName, lastName, age) {
this.firstName = firstName;
this.lastName = lastName;
this.age = age;
}
var family = {};
family.mother = new Person("Susan", "Doyle", 32);
family.father = new Person("John", "Doyle", 33);
family.daughter = new Person("Lily", "Doyle", 5);
family.son = new Person("Mike", "Doyle", 8);
console.ietable(family, ["firstName", "lastName", "age"]);
We get:
index | firstName | lastName | age
mother | Susan | Doyle | 32
father | John | Doyle | 33
daughter | Lily | Doyle | 5
son | Mike | Doyle | 8
Similar to: