Some Scripting languages (e.g. TypeScript since recently, and as it seems also some JavaScript implementations) provide a new operator: "?."
It is a shortcut operator: The purpose is to access variables of an object, but first checking if the object or variable is actually defined. This would avoid a lot of extra if(undefined) checking in many medini scripts.
Assume for instance that you want to print the last name of the customer that is related with a certain order.
Traditionally you write something like
console.log(currentOrder.customer.lastName);
but the script breaks when there is no customer or the customer's last name is undefined. So you need to implement some extra checks by hand.
With the new operator it would be
console.log(currentOrder?.customer?.lastName);
The access is only executed if the object is defined.
Any chances to get a JavaScript Interpreter version into medini that can support this?