What is the role of brackets ([ ]) in JavaScript Regular Expressions?

HTMLJavascriptProgramming Scripts

As per my knowledge ([]) is used in Knockout.js this is used to define the observableArray. Please find the example and link below.

// This observable array initially contains three objects
var anotherObservableArray = ko.observableArray([
    { name: "Bungle", type: "Bear" },
    { name: "George", type: "Hippo" },
    { name: "Zippy", type: "Unknown" }
]);

http://knockoutjs.com/documentation/observableArrays.html

raja
Published on 22-Apr-2018 19:14:59
Advertisements