Dart has some null-aware operators, i.e. it is possible to do
var obj; obj?.foo(); // foo is only called if obj != null.
Is this also possi
Form the docs:
Dart is a true object-oriented language, so even functions are objects and have a type, Function.
Apply the null aware ?. operator to the call method of function objects:
?.
call
typedef void SomeFunc(); SomeFunc f = null; f?.call();