I’d like to be able to do
console.log(some_value);
instead of
console.log(some_object.attributes.some_value);
Is there a way to make that object’s attributes available in the current ‘scope’ (‘scope’ isn’t the word I’m looking for, but I hope you understand what I’m asking).
I’m searching somethin like the ‘with’ syntax in Classic ASP, where you can do
Dim myObject = Server.CreateObject(".......")
with myObject
.method1()
.property1 = "Test"
end with
Regards
Yes you can use
withstatement for that: