Become a member
to unlock all features

Create an egghead account to access 5000+ tutorials and resources from expert developers.

Create account

    Define Optional Named and Positional Parameters for Functions and Methods in Dart


    In this lesson, we will look at the different forms of creating parameters that are optional, namely positional and named. Optional positional arguments are useful when specifying a default value for a particular parameter. Optional named parameters are useful for specifying parameter defaults and writing self-documenting functions and methods.