EnhancedDropDown.withEndpoint constructor

EnhancedDropDown.withEndpoint({
  1. required String dropdownLabelTitle,
  2. required String defaultOptionText,
  3. required Uri? urlToFetchData,
  4. required ValueChanged valueReturned,
  5. String? fieldToPresent,
})

Constructor that accepts an endpoint in URI form to fetch the data from

Implementation

EnhancedDropDown.withEndpoint(
    {required this.dropdownLabelTitle,
    required this.defaultOptionText,
    required this.urlToFetchData,
    required this.valueReturned,
    this.fieldToPresent})
    : dataSource = null;