-
Notifications
You must be signed in to change notification settings - Fork 10
Closed
Labels
Milestone
Description
Many DOM objects like HTMLCollection
[1] supports array like usage with square brackets
Example from MDN
let elem1, elem2;
// document.forms is an HTMLCollection
elem1 = document.forms[0];
elem2 = document.forms.item(0);
alert(elem1 === elem2); // shows: "true"
elem1 = document.forms.myForm;
elem2 = document.forms.namedItem("myForm");
alert(elem1 === elem2); // shows: "true"
elem1 = document.forms["named.item.with.periods"];
jsruntime-lib should allow to implement the array like syntax (getter and setter) with a native struct.